{
    "schemaVersion": "2.0.0",
    "contractName": "UniswapBridge",
    "compilerOutput": {
        "abi": [
            {
                "anonymous": false,
                "inputs": [
                    {
                        "indexed": false,
                        "internalType": "address",
                        "name": "inputToken",
                        "type": "address"
                    },
                    {
                        "indexed": false,
                        "internalType": "address",
                        "name": "outputToken",
                        "type": "address"
                    },
                    {
                        "indexed": false,
                        "internalType": "uint256",
                        "name": "inputTokenAmount",
                        "type": "uint256"
                    },
                    {
                        "indexed": false,
                        "internalType": "uint256",
                        "name": "outputTokenAmount",
                        "type": "uint256"
                    },
                    {
                        "indexed": false,
                        "internalType": "address",
                        "name": "from",
                        "type": "address"
                    },
                    {
                        "indexed": false,
                        "internalType": "address",
                        "name": "to",
                        "type": "address"
                    }
                ],
                "name": "ERC20BridgeTransfer",
                "type": "event"
            },
            {
                "payable": true,
                "stateMutability": "payable",
                "type": "fallback"
            },
            {
                "constant": false,
                "inputs": [
                    {
                        "internalType": "address",
                        "name": "toTokenAddress",
                        "type": "address"
                    },
                    {
                        "internalType": "address",
                        "name": "from",
                        "type": "address"
                    },
                    {
                        "internalType": "address",
                        "name": "to",
                        "type": "address"
                    },
                    {
                        "internalType": "uint256",
                        "name": "amount",
                        "type": "uint256"
                    },
                    {
                        "internalType": "bytes",
                        "name": "bridgeData",
                        "type": "bytes"
                    }
                ],
                "name": "bridgeTransferFrom",
                "outputs": [
                    {
                        "internalType": "bytes4",
                        "name": "success",
                        "type": "bytes4"
                    }
                ],
                "payable": false,
                "stateMutability": "nonpayable",
                "type": "function"
            },
            {
                "constant": true,
                "inputs": [
                    {
                        "internalType": "bytes32",
                        "name": "",
                        "type": "bytes32"
                    },
                    {
                        "internalType": "bytes",
                        "name": "",
                        "type": "bytes"
                    }
                ],
                "name": "isValidSignature",
                "outputs": [
                    {
                        "internalType": "bytes4",
                        "name": "magicValue",
                        "type": "bytes4"
                    }
                ],
                "payable": false,
                "stateMutability": "view",
                "type": "function"
            }
        ],
        "devdoc": {
            "methods": {
                "bridgeTransferFrom(address,address,address,uint256,bytes)": {
                    "details": "Callback for `IERC20Bridge`. Tries to buy `amount` of      `toTokenAddress` tokens by selling the entirety of the `fromTokenAddress`      token encoded in the bridge data.",
                    "params": {
                        "amount": "Minimum amount of `toTokenAddress` tokens to buy.",
                        "bridgeData": "The abi-encoded \"from\" token address.",
                        "from": "The maker (this contract).",
                        "to": "The recipient of the bought tokens.",
                        "toTokenAddress": "The token to buy and transfer to `to`."
                    },
                    "return": "success The magic bytes if successful."
                },
                "isValidSignature(bytes32,bytes)": {
                    "details": "`SignatureType.Wallet` callback, so that this bridge can be the maker      and sign for itself in orders. Always succeeds.",
                    "return": "magicValue Success bytes, always."
                }
            }
        },
        "evm": {
            "bytecode": {
                "linkReferences": {},
                "object": "0x608060405234801561001057600080fd5b50610fbd806100206000396000f3fe6080604052600436106100295760003560e01c80631626ba7e1461002b578063c2df82e614610061575b005b34801561003757600080fd5b5061004b610046366004610cf3565b610081565b6040516100589190610e43565b60405180910390f35b34801561006d57600080fd5b5061004b61007c366004610c50565b6100a9565b7fb0671381000000000000000000000000000000000000000000000000000000009392505050565b60006100b3610b7d565b60006100c184860186610c34565b90508873ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141561012d5761010281888861068c565b507fdc1600f30000000000000000000000000000000000000000000000000000000091506106829050565b610137818a610753565b73ffffffffffffffffffffffffffffffffffffffff90811683526040517f70a08231000000000000000000000000000000000000000000000000000000008152908216906370a082319061018f903090600401610d8e565b60206040518083038186803b1580156101a757600080fd5b505afa1580156101bb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506101df9190810190610d3d565b60208301526101ec610883565b73ffffffffffffffffffffffffffffffffffffffff90811660408401819052908216141561034257816040015173ffffffffffffffffffffffffffffffffffffffff16632e1a7d4d83602001516040518263ffffffff1660e01b81526004016102559190610ec9565b600060405180830381600087803b15801561026f57600080fd5b505af1158015610283573d6000803e3d6000fd5b5050835160208501516040517fad65d76d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff909216935063ad65d76d9250906102e6908a9042908d90600401610ed2565b6020604051808303818588803b1580156102ff57600080fd5b505af1158015610313573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052506103389190810190610d3d565b6060830152610613565b816040015173ffffffffffffffffffffffffffffffffffffffff168973ffffffffffffffffffffffffffffffffffffffff16141561055c5761038d826000015182846020015161089b565b815160208301516040517f95e3c50b00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff909216916395e3c50b916103e9918a904290600401610f3f565b602060405180830381600087803b15801561040357600080fd5b505af1158015610417573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061043b9190810190610d3d565b826060018181525050816040015173ffffffffffffffffffffffffffffffffffffffff1663d0e30db083606001516040518263ffffffff1660e01b81526004016000604051808303818588803b15801561049457600080fd5b505af11580156104a8573d6000803e3d6000fd5b50505060608401516040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8d16935063a9059cbb9250610504918b91600401610e1d565b602060405180830381600087803b15801561051e57600080fd5b505af1158015610532573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506105569190810190610cd3565b50610613565b61056f826000015182846020015161089b565b816000015173ffffffffffffffffffffffffffffffffffffffff1663f552d91b8360200151886001428c8f6040518763ffffffff1660e01b81526004016105bb96959493929190610efe565b602060405180830381600087803b1580156105d557600080fd5b505af11580156105e9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061060d9190810190610d3d565b60608301525b7f349fc08071558d8e3aa92dec9396e4e9f2dfecd6bb9065759d1932e7da43b8a9818a846020015185606001518c8c60405161065496959493929190610dd6565b60405180910390a1507fdc1600f3000000000000000000000000000000000000000000000000000000009150505b9695505050505050565b6040516060907fa9059cbb00000000000000000000000000000000000000000000000000000000906106c49085908590602401610e1d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152905061074d84826108ab565b50505050565b60008261075e610883565b73ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156107945750815b61079c610967565b73ffffffffffffffffffffffffffffffffffffffff166306f2bf62826040518263ffffffff1660e01b81526004016107d49190610d8e565b60206040518083038186803b1580156107ec57600080fd5b505afa158015610800573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506108249190810190610c18565b915073ffffffffffffffffffffffffffffffffffffffff821661087c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161087390610e92565b60405180910390fd5b5092915050565b73c02aaa39b223fe8d0a0e5c4f27ead9083c756cc290565b6108a682848361097f565b505050565b600060608373ffffffffffffffffffffffffffffffffffffffff16836040516108d49190610d55565b6000604051808303816000865af19150503d8060008114610911576040519150601f19603f3d011682016040523d82523d6000602084013e610916565b606091505b5091509150811561095a57805161092e575050610963565b80516020141561095a576000610945826000610a56565b9050806001141561095857505050610963565b505b61074d81610a69565b5050565b73c0a47dfe034b400b47bdad5fecda2621de6c4d9590565b6040517fdd62ed3e000000000000000000000000000000000000000000000000000000008152819073ffffffffffffffffffffffffffffffffffffffff85169063dd62ed3e906109d59030908790600401610daf565b60206040518083038186803b1580156109ed57600080fd5b505afa158015610a01573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250610a259190810190610d3d565b10156108a6576108a683837fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff610a71565b6000610a628383610aa9565b9392505050565b805160208201fd5b6040516060907f095ea7b300000000000000000000000000000000000000000000000000000000906106c49085908590602401610e1d565b60008160200183511015610acf57610acf610aca6005855185602001610ad8565b610a69565b50016020015190565b6060632800659560e01b848484604051602401610af793929190610e70565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915290509392505050565b6040518060800160405280600073ffffffffffffffffffffffffffffffffffffffff16815260200160008152602001600073ffffffffffffffffffffffffffffffffffffffff168152602001600081525090565b60008083601f840112610be2578182fd5b50813567ffffffffffffffff811115610bf9578182fd5b602083019150836020828501011115610c1157600080fd5b9250929050565b600060208284031215610c29578081fd5b8151610a6281610f55565b600060208284031215610c45578081fd5b8135610a6281610f55565b60008060008060008060a08789031215610c68578182fd5b8635610c7381610f55565b95506020870135610c8381610f55565b94506040870135610c9381610f55565b935060608701359250608087013567ffffffffffffffff811115610cb5578283fd5b610cc189828a01610bd1565b979a9699509497509295939492505050565b600060208284031215610ce4578081fd5b81518015158114610a62578182fd5b600080600060408486031215610d07578283fd5b83359250602084013567ffffffffffffffff811115610d24578283fd5b610d3086828701610bd1565b9497909650939450505050565b600060208284031215610d4e578081fd5b5051919050565b60008251815b81811015610d755760208186018101518583015201610d5b565b81811115610d835782828501525b509190910192915050565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b73ffffffffffffffffffffffffffffffffffffffff92831681529116602082015260400190565b73ffffffffffffffffffffffffffffffffffffffff96871681529486166020860152604085019390935260608401919091528316608083015290911660a082015260c00190565b73ffffffffffffffffffffffffffffffffffffffff929092168252602082015260400190565b7fffffffff0000000000000000000000000000000000000000000000000000000091909116815260200190565b6060810160088510610e7e57fe5b938152602081019290925260409091015290565b6020808252601d908201527f4e4f5f554e49535741505f45584348414e47455f464f525f544f4b454e000000604082015260600190565b90815260200190565b928352602083019190915273ffffffffffffffffffffffffffffffffffffffff16604082015260600190565b95865260208601949094526040850192909252606084015273ffffffffffffffffffffffffffffffffffffffff90811660808401521660a082015260c00190565b9283526020830191909152604082015260600190565b73ffffffffffffffffffffffffffffffffffffffff81168114610f7757600080fd5b5056fea365627a7a7231582022afd1a7f0bd852b2a907eac59d84282d622a65993689c446c07cb00cc7388bd6c6578706572696d656e74616cf564736f6c63430005110040",
                "opcodes": "PUSH1 0x80 PUSH1 0x40 MSTORE CALLVALUE DUP1 ISZERO PUSH2 0x10 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH2 0xFBD DUP1 PUSH2 0x20 PUSH1 0x0 CODECOPY PUSH1 0x0 RETURN INVALID PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x4 CALLDATASIZE LT PUSH2 0x29 JUMPI PUSH1 0x0 CALLDATALOAD PUSH1 0xE0 SHR DUP1 PUSH4 0x1626BA7E EQ PUSH2 0x2B JUMPI DUP1 PUSH4 0xC2DF82E6 EQ PUSH2 0x61 JUMPI JUMPDEST STOP JUMPDEST CALLVALUE DUP1 ISZERO PUSH2 0x37 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH2 0x4B PUSH2 0x46 CALLDATASIZE PUSH1 0x4 PUSH2 0xCF3 JUMP JUMPDEST PUSH2 0x81 JUMP JUMPDEST PUSH1 0x40 MLOAD PUSH2 0x58 SWAP2 SWAP1 PUSH2 0xE43 JUMP JUMPDEST PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 RETURN JUMPDEST CALLVALUE DUP1 ISZERO PUSH2 0x6D JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH2 0x4B PUSH2 0x7C CALLDATASIZE PUSH1 0x4 PUSH2 0xC50 JUMP JUMPDEST PUSH2 0xA9 JUMP JUMPDEST PUSH32 0xB067138100000000000000000000000000000000000000000000000000000000 SWAP4 SWAP3 POP POP POP JUMP JUMPDEST PUSH1 0x0 PUSH2 0xB3 PUSH2 0xB7D JUMP JUMPDEST PUSH1 0x0 PUSH2 0xC1 DUP5 DUP7 ADD DUP7 PUSH2 0xC34 JUMP JUMPDEST SWAP1 POP DUP9 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP2 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND EQ ISZERO PUSH2 0x12D JUMPI PUSH2 0x102 DUP2 DUP9 DUP9 PUSH2 0x68C JUMP JUMPDEST POP PUSH32 0xDC1600F300000000000000000000000000000000000000000000000000000000 SWAP2 POP PUSH2 0x682 SWAP1 POP JUMP JUMPDEST PUSH2 0x137 DUP2 DUP11 PUSH2 0x753 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP1 DUP2 AND DUP4 MSTORE PUSH1 0x40 MLOAD PUSH32 0x70A0823100000000000000000000000000000000000000000000000000000000 DUP2 MSTORE SWAP1 DUP3 AND SWAP1 PUSH4 0x70A08231 SWAP1 PUSH2 0x18F SWAP1 ADDRESS SWAP1 PUSH1 0x4 ADD PUSH2 0xD8E JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x1A7 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x1BB JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x1DF SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xD3D JUMP JUMPDEST PUSH1 0x20 DUP4 ADD MSTORE PUSH2 0x1EC PUSH2 0x883 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP1 DUP2 AND PUSH1 0x40 DUP5 ADD DUP2 SWAP1 MSTORE SWAP1 DUP3 AND EQ ISZERO PUSH2 0x342 JUMPI DUP2 PUSH1 0x40 ADD MLOAD PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH4 0x2E1A7D4D DUP4 PUSH1 0x20 ADD MLOAD PUSH1 0x40 MLOAD DUP3 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH2 0x255 SWAP2 SWAP1 PUSH2 0xEC9 JUMP JUMPDEST PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x26F JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x283 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP DUP4 MLOAD PUSH1 0x20 DUP6 ADD MLOAD PUSH1 0x40 MLOAD PUSH32 0xAD65D76D00000000000000000000000000000000000000000000000000000000 DUP2 MSTORE PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP1 SWAP3 AND SWAP4 POP PUSH4 0xAD65D76D SWAP3 POP SWAP1 PUSH2 0x2E6 SWAP1 DUP11 SWAP1 TIMESTAMP SWAP1 DUP14 SWAP1 PUSH1 0x4 ADD PUSH2 0xED2 JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP6 DUP9 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x2FF JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x313 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x338 SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xD3D JUMP JUMPDEST PUSH1 0x60 DUP4 ADD MSTORE PUSH2 0x613 JUMP JUMPDEST DUP2 PUSH1 0x40 ADD MLOAD PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP10 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND EQ ISZERO PUSH2 0x55C JUMPI PUSH2 0x38D DUP3 PUSH1 0x0 ADD MLOAD DUP3 DUP5 PUSH1 0x20 ADD MLOAD PUSH2 0x89B JUMP JUMPDEST DUP2 MLOAD PUSH1 0x20 DUP4 ADD MLOAD PUSH1 0x40 MLOAD PUSH32 0x95E3C50B00000000000000000000000000000000000000000000000000000000 DUP2 MSTORE PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP1 SWAP3 AND SWAP2 PUSH4 0x95E3C50B SWAP2 PUSH2 0x3E9 SWAP2 DUP11 SWAP1 TIMESTAMP SWAP1 PUSH1 0x4 ADD PUSH2 0xF3F JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x403 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x417 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x43B SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xD3D JUMP JUMPDEST DUP3 PUSH1 0x60 ADD DUP2 DUP2 MSTORE POP POP DUP2 PUSH1 0x40 ADD MLOAD PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH4 0xD0E30DB0 DUP4 PUSH1 0x60 ADD MLOAD PUSH1 0x40 MLOAD DUP3 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP6 DUP9 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x494 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x4A8 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP PUSH1 0x60 DUP5 ADD MLOAD PUSH1 0x40 MLOAD PUSH32 0xA9059CBB00000000000000000000000000000000000000000000000000000000 DUP2 MSTORE PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF DUP14 AND SWAP4 POP PUSH4 0xA9059CBB SWAP3 POP PUSH2 0x504 SWAP2 DUP12 SWAP2 PUSH1 0x4 ADD PUSH2 0xE1D JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x51E JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x532 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x556 SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xCD3 JUMP JUMPDEST POP PUSH2 0x613 JUMP JUMPDEST PUSH2 0x56F DUP3 PUSH1 0x0 ADD MLOAD DUP3 DUP5 PUSH1 0x20 ADD MLOAD PUSH2 0x89B JUMP JUMPDEST DUP2 PUSH1 0x0 ADD MLOAD PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH4 0xF552D91B DUP4 PUSH1 0x20 ADD MLOAD DUP9 PUSH1 0x1 TIMESTAMP DUP13 DUP16 PUSH1 0x40 MLOAD DUP8 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH2 0x5BB SWAP7 SWAP6 SWAP5 SWAP4 SWAP3 SWAP2 SWAP1 PUSH2 0xEFE JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x5D5 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x5E9 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x60D SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xD3D JUMP JUMPDEST PUSH1 0x60 DUP4 ADD MSTORE JUMPDEST PUSH32 0x349FC08071558D8E3AA92DEC9396E4E9F2DFECD6BB9065759D1932E7DA43B8A9 DUP2 DUP11 DUP5 PUSH1 0x20 ADD MLOAD DUP6 PUSH1 0x60 ADD MLOAD DUP13 DUP13 PUSH1 0x40 MLOAD PUSH2 0x654 SWAP7 SWAP6 SWAP5 SWAP4 SWAP3 SWAP2 SWAP1 PUSH2 0xDD6 JUMP JUMPDEST PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 LOG1 POP PUSH32 0xDC1600F300000000000000000000000000000000000000000000000000000000 SWAP2 POP POP JUMPDEST SWAP7 SWAP6 POP POP POP POP POP POP JUMP JUMPDEST PUSH1 0x40 MLOAD PUSH1 0x60 SWAP1 PUSH32 0xA9059CBB00000000000000000000000000000000000000000000000000000000 SWAP1 PUSH2 0x6C4 SWAP1 DUP6 SWAP1 DUP6 SWAP1 PUSH1 0x24 ADD PUSH2 0xE1D JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH32 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFE0 DUP2 DUP5 SUB ADD DUP2 MSTORE SWAP2 SWAP1 MSTORE PUSH1 0x20 DUP2 ADD DUP1 MLOAD PUSH28 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH32 0xFFFFFFFF00000000000000000000000000000000000000000000000000000000 SWAP1 SWAP4 AND SWAP3 SWAP1 SWAP3 OR SWAP1 SWAP2 MSTORE SWAP1 POP PUSH2 0x74D DUP5 DUP3 PUSH2 0x8AB JUMP JUMPDEST POP POP POP POP JUMP JUMPDEST PUSH1 0x0 DUP3 PUSH2 0x75E PUSH2 0x883 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP5 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND EQ ISZERO PUSH2 0x794 JUMPI POP DUP2 JUMPDEST PUSH2 0x79C PUSH2 0x967 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH4 0x6F2BF62 DUP3 PUSH1 0x40 MLOAD DUP3 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH2 0x7D4 SWAP2 SWAP1 PUSH2 0xD8E JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x7EC JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x800 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x824 SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xC18 JUMP JUMPDEST SWAP2 POP PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF DUP3 AND PUSH2 0x87C JUMPI PUSH1 0x40 MLOAD PUSH32 0x8C379A000000000000000000000000000000000000000000000000000000000 DUP2 MSTORE PUSH1 0x4 ADD PUSH2 0x873 SWAP1 PUSH2 0xE92 JUMP JUMPDEST PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST POP SWAP3 SWAP2 POP POP JUMP JUMPDEST PUSH20 0xC02AAA39B223FE8D0A0E5C4F27EAD9083C756CC2 SWAP1 JUMP JUMPDEST PUSH2 0x8A6 DUP3 DUP5 DUP4 PUSH2 0x97F JUMP JUMPDEST POP POP POP JUMP JUMPDEST PUSH1 0x0 PUSH1 0x60 DUP4 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP4 PUSH1 0x40 MLOAD PUSH2 0x8D4 SWAP2 SWAP1 PUSH2 0xD55 JUMP JUMPDEST PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP7 GAS CALL SWAP2 POP POP RETURNDATASIZE DUP1 PUSH1 0x0 DUP2 EQ PUSH2 0x911 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 0x916 JUMP JUMPDEST PUSH1 0x60 SWAP2 POP JUMPDEST POP SWAP2 POP SWAP2 POP DUP2 ISZERO PUSH2 0x95A JUMPI DUP1 MLOAD PUSH2 0x92E JUMPI POP POP PUSH2 0x963 JUMP JUMPDEST DUP1 MLOAD PUSH1 0x20 EQ ISZERO PUSH2 0x95A JUMPI PUSH1 0x0 PUSH2 0x945 DUP3 PUSH1 0x0 PUSH2 0xA56 JUMP JUMPDEST SWAP1 POP DUP1 PUSH1 0x1 EQ ISZERO PUSH2 0x958 JUMPI POP POP POP PUSH2 0x963 JUMP JUMPDEST POP JUMPDEST PUSH2 0x74D DUP2 PUSH2 0xA69 JUMP JUMPDEST POP POP JUMP JUMPDEST PUSH20 0xC0A47DFE034B400B47BDAD5FECDA2621DE6C4D95 SWAP1 JUMP JUMPDEST PUSH1 0x40 MLOAD PUSH32 0xDD62ED3E00000000000000000000000000000000000000000000000000000000 DUP2 MSTORE DUP2 SWAP1 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF DUP6 AND SWAP1 PUSH4 0xDD62ED3E SWAP1 PUSH2 0x9D5 SWAP1 ADDRESS SWAP1 DUP8 SWAP1 PUSH1 0x4 ADD PUSH2 0xDAF JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x9ED JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0xA01 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0xA25 SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xD3D JUMP JUMPDEST LT ISZERO PUSH2 0x8A6 JUMPI PUSH2 0x8A6 DUP4 DUP4 PUSH32 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF PUSH2 0xA71 JUMP JUMPDEST PUSH1 0x0 PUSH2 0xA62 DUP4 DUP4 PUSH2 0xAA9 JUMP JUMPDEST SWAP4 SWAP3 POP POP POP JUMP JUMPDEST DUP1 MLOAD PUSH1 0x20 DUP3 ADD REVERT JUMPDEST PUSH1 0x40 MLOAD PUSH1 0x60 SWAP1 PUSH32 0x95EA7B300000000000000000000000000000000000000000000000000000000 SWAP1 PUSH2 0x6C4 SWAP1 DUP6 SWAP1 DUP6 SWAP1 PUSH1 0x24 ADD PUSH2 0xE1D JUMP JUMPDEST PUSH1 0x0 DUP2 PUSH1 0x20 ADD DUP4 MLOAD LT ISZERO PUSH2 0xACF JUMPI PUSH2 0xACF PUSH2 0xACA PUSH1 0x5 DUP6 MLOAD DUP6 PUSH1 0x20 ADD PUSH2 0xAD8 JUMP JUMPDEST PUSH2 0xA69 JUMP JUMPDEST POP ADD PUSH1 0x20 ADD MLOAD SWAP1 JUMP JUMPDEST PUSH1 0x60 PUSH4 0x28006595 PUSH1 0xE0 SHL DUP5 DUP5 DUP5 PUSH1 0x40 MLOAD PUSH1 0x24 ADD PUSH2 0xAF7 SWAP4 SWAP3 SWAP2 SWAP1 PUSH2 0xE70 JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH32 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFE0 DUP2 DUP5 SUB ADD DUP2 MSTORE SWAP2 SWAP1 MSTORE PUSH1 0x20 DUP2 ADD DUP1 MLOAD PUSH28 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH32 0xFFFFFFFF00000000000000000000000000000000000000000000000000000000 SWAP1 SWAP4 AND SWAP3 SWAP1 SWAP3 OR SWAP1 SWAP2 MSTORE SWAP1 POP SWAP4 SWAP3 POP POP POP JUMP JUMPDEST PUSH1 0x40 MLOAD DUP1 PUSH1 0x80 ADD PUSH1 0x40 MSTORE DUP1 PUSH1 0x0 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP2 MSTORE PUSH1 0x20 ADD PUSH1 0x0 DUP2 MSTORE PUSH1 0x20 ADD PUSH1 0x0 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP2 MSTORE PUSH1 0x20 ADD PUSH1 0x0 DUP2 MSTORE POP SWAP1 JUMP JUMPDEST PUSH1 0x0 DUP1 DUP4 PUSH1 0x1F DUP5 ADD SLT PUSH2 0xBE2 JUMPI DUP2 DUP3 REVERT JUMPDEST POP DUP2 CALLDATALOAD PUSH8 0xFFFFFFFFFFFFFFFF DUP2 GT ISZERO PUSH2 0xBF9 JUMPI DUP2 DUP3 REVERT JUMPDEST PUSH1 0x20 DUP4 ADD SWAP2 POP DUP4 PUSH1 0x20 DUP3 DUP6 ADD ADD GT ISZERO PUSH2 0xC11 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST SWAP3 POP SWAP3 SWAP1 POP JUMP JUMPDEST PUSH1 0x0 PUSH1 0x20 DUP3 DUP5 SUB SLT ISZERO PUSH2 0xC29 JUMPI DUP1 DUP2 REVERT JUMPDEST DUP2 MLOAD PUSH2 0xA62 DUP2 PUSH2 0xF55 JUMP JUMPDEST PUSH1 0x0 PUSH1 0x20 DUP3 DUP5 SUB SLT ISZERO PUSH2 0xC45 JUMPI DUP1 DUP2 REVERT JUMPDEST DUP2 CALLDATALOAD PUSH2 0xA62 DUP2 PUSH2 0xF55 JUMP JUMPDEST PUSH1 0x0 DUP1 PUSH1 0x0 DUP1 PUSH1 0x0 DUP1 PUSH1 0xA0 DUP8 DUP10 SUB SLT ISZERO PUSH2 0xC68 JUMPI DUP2 DUP3 REVERT JUMPDEST DUP7 CALLDATALOAD PUSH2 0xC73 DUP2 PUSH2 0xF55 JUMP JUMPDEST SWAP6 POP PUSH1 0x20 DUP8 ADD CALLDATALOAD PUSH2 0xC83 DUP2 PUSH2 0xF55 JUMP JUMPDEST SWAP5 POP PUSH1 0x40 DUP8 ADD CALLDATALOAD PUSH2 0xC93 DUP2 PUSH2 0xF55 JUMP JUMPDEST SWAP4 POP PUSH1 0x60 DUP8 ADD CALLDATALOAD SWAP3 POP PUSH1 0x80 DUP8 ADD CALLDATALOAD PUSH8 0xFFFFFFFFFFFFFFFF DUP2 GT ISZERO PUSH2 0xCB5 JUMPI DUP3 DUP4 REVERT JUMPDEST PUSH2 0xCC1 DUP10 DUP3 DUP11 ADD PUSH2 0xBD1 JUMP JUMPDEST SWAP8 SWAP11 SWAP7 SWAP10 POP SWAP5 SWAP8 POP SWAP3 SWAP6 SWAP4 SWAP5 SWAP3 POP POP POP JUMP JUMPDEST PUSH1 0x0 PUSH1 0x20 DUP3 DUP5 SUB SLT ISZERO PUSH2 0xCE4 JUMPI DUP1 DUP2 REVERT JUMPDEST DUP2 MLOAD DUP1 ISZERO ISZERO DUP2 EQ PUSH2 0xA62 JUMPI DUP2 DUP3 REVERT JUMPDEST PUSH1 0x0 DUP1 PUSH1 0x0 PUSH1 0x40 DUP5 DUP7 SUB SLT ISZERO PUSH2 0xD07 JUMPI DUP3 DUP4 REVERT JUMPDEST DUP4 CALLDATALOAD SWAP3 POP PUSH1 0x20 DUP5 ADD CALLDATALOAD PUSH8 0xFFFFFFFFFFFFFFFF DUP2 GT ISZERO PUSH2 0xD24 JUMPI DUP3 DUP4 REVERT JUMPDEST PUSH2 0xD30 DUP7 DUP3 DUP8 ADD PUSH2 0xBD1 JUMP JUMPDEST SWAP5 SWAP8 SWAP1 SWAP7 POP SWAP4 SWAP5 POP POP POP POP JUMP JUMPDEST PUSH1 0x0 PUSH1 0x20 DUP3 DUP5 SUB SLT ISZERO PUSH2 0xD4E JUMPI DUP1 DUP2 REVERT JUMPDEST POP MLOAD SWAP2 SWAP1 POP JUMP JUMPDEST PUSH1 0x0 DUP3 MLOAD DUP2 JUMPDEST DUP2 DUP2 LT ISZERO PUSH2 0xD75 JUMPI PUSH1 0x20 DUP2 DUP7 ADD DUP2 ADD MLOAD DUP6 DUP4 ADD MSTORE ADD PUSH2 0xD5B JUMP JUMPDEST DUP2 DUP2 GT ISZERO PUSH2 0xD83 JUMPI DUP3 DUP3 DUP6 ADD MSTORE JUMPDEST POP SWAP2 SWAP1 SWAP2 ADD SWAP3 SWAP2 POP POP JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP2 SWAP1 SWAP2 AND DUP2 MSTORE PUSH1 0x20 ADD SWAP1 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP3 DUP4 AND DUP2 MSTORE SWAP2 AND PUSH1 0x20 DUP3 ADD MSTORE PUSH1 0x40 ADD SWAP1 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP7 DUP8 AND DUP2 MSTORE SWAP5 DUP7 AND PUSH1 0x20 DUP7 ADD MSTORE PUSH1 0x40 DUP6 ADD SWAP4 SWAP1 SWAP4 MSTORE PUSH1 0x60 DUP5 ADD SWAP2 SWAP1 SWAP2 MSTORE DUP4 AND PUSH1 0x80 DUP4 ADD MSTORE SWAP1 SWAP2 AND PUSH1 0xA0 DUP3 ADD MSTORE PUSH1 0xC0 ADD SWAP1 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP3 SWAP1 SWAP3 AND DUP3 MSTORE PUSH1 0x20 DUP3 ADD MSTORE PUSH1 0x40 ADD SWAP1 JUMP JUMPDEST PUSH32 0xFFFFFFFF00000000000000000000000000000000000000000000000000000000 SWAP2 SWAP1 SWAP2 AND DUP2 MSTORE PUSH1 0x20 ADD SWAP1 JUMP JUMPDEST PUSH1 0x60 DUP2 ADD PUSH1 0x8 DUP6 LT PUSH2 0xE7E JUMPI INVALID JUMPDEST SWAP4 DUP2 MSTORE PUSH1 0x20 DUP2 ADD SWAP3 SWAP1 SWAP3 MSTORE PUSH1 0x40 SWAP1 SWAP2 ADD MSTORE SWAP1 JUMP JUMPDEST PUSH1 0x20 DUP1 DUP3 MSTORE PUSH1 0x1D SWAP1 DUP3 ADD MSTORE PUSH32 0x4E4F5F554E49535741505F45584348414E47455F464F525F544F4B454E000000 PUSH1 0x40 DUP3 ADD MSTORE PUSH1 0x60 ADD SWAP1 JUMP JUMPDEST SWAP1 DUP2 MSTORE PUSH1 0x20 ADD SWAP1 JUMP JUMPDEST SWAP3 DUP4 MSTORE PUSH1 0x20 DUP4 ADD SWAP2 SWAP1 SWAP2 MSTORE PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH1 0x40 DUP3 ADD MSTORE PUSH1 0x60 ADD SWAP1 JUMP JUMPDEST SWAP6 DUP7 MSTORE PUSH1 0x20 DUP7 ADD SWAP5 SWAP1 SWAP5 MSTORE PUSH1 0x40 DUP6 ADD SWAP3 SWAP1 SWAP3 MSTORE PUSH1 0x60 DUP5 ADD MSTORE PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP1 DUP2 AND PUSH1 0x80 DUP5 ADD MSTORE AND PUSH1 0xA0 DUP3 ADD MSTORE PUSH1 0xC0 ADD SWAP1 JUMP JUMPDEST SWAP3 DUP4 MSTORE PUSH1 0x20 DUP4 ADD SWAP2 SWAP1 SWAP2 MSTORE PUSH1 0x40 DUP3 ADD MSTORE PUSH1 0x60 ADD SWAP1 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF DUP2 AND DUP2 EQ PUSH2 0xF77 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP JUMP INVALID LOG3 PUSH6 0x627A7A723158 KECCAK256 0x22 0xAF 0xD1 0xA7 CREATE 0xBD DUP6 0x2B 0x2A SWAP1 PUSH31 0xAC59D84282D622A65993689C446C07CB00CC7388BD6C6578706572696D656E PUSH21 0x616CF564736F6C6343000511004000000000000000 ",
                "sourceMap": "1188:6843:27:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1188:6843:27;;;;;;;"
            },
            "deployedBytecode": {
                "linkReferences": {},
                "object": "0x6080604052600436106100295760003560e01c80631626ba7e1461002b578063c2df82e614610061575b005b34801561003757600080fd5b5061004b610046366004610cf3565b610081565b6040516100589190610e43565b60405180910390f35b34801561006d57600080fd5b5061004b61007c366004610c50565b6100a9565b7fb0671381000000000000000000000000000000000000000000000000000000009392505050565b60006100b3610b7d565b60006100c184860186610c34565b90508873ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141561012d5761010281888861068c565b507fdc1600f30000000000000000000000000000000000000000000000000000000091506106829050565b610137818a610753565b73ffffffffffffffffffffffffffffffffffffffff90811683526040517f70a08231000000000000000000000000000000000000000000000000000000008152908216906370a082319061018f903090600401610d8e565b60206040518083038186803b1580156101a757600080fd5b505afa1580156101bb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506101df9190810190610d3d565b60208301526101ec610883565b73ffffffffffffffffffffffffffffffffffffffff90811660408401819052908216141561034257816040015173ffffffffffffffffffffffffffffffffffffffff16632e1a7d4d83602001516040518263ffffffff1660e01b81526004016102559190610ec9565b600060405180830381600087803b15801561026f57600080fd5b505af1158015610283573d6000803e3d6000fd5b5050835160208501516040517fad65d76d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff909216935063ad65d76d9250906102e6908a9042908d90600401610ed2565b6020604051808303818588803b1580156102ff57600080fd5b505af1158015610313573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052506103389190810190610d3d565b6060830152610613565b816040015173ffffffffffffffffffffffffffffffffffffffff168973ffffffffffffffffffffffffffffffffffffffff16141561055c5761038d826000015182846020015161089b565b815160208301516040517f95e3c50b00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff909216916395e3c50b916103e9918a904290600401610f3f565b602060405180830381600087803b15801561040357600080fd5b505af1158015610417573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061043b9190810190610d3d565b826060018181525050816040015173ffffffffffffffffffffffffffffffffffffffff1663d0e30db083606001516040518263ffffffff1660e01b81526004016000604051808303818588803b15801561049457600080fd5b505af11580156104a8573d6000803e3d6000fd5b50505060608401516040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8d16935063a9059cbb9250610504918b91600401610e1d565b602060405180830381600087803b15801561051e57600080fd5b505af1158015610532573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506105569190810190610cd3565b50610613565b61056f826000015182846020015161089b565b816000015173ffffffffffffffffffffffffffffffffffffffff1663f552d91b8360200151886001428c8f6040518763ffffffff1660e01b81526004016105bb96959493929190610efe565b602060405180830381600087803b1580156105d557600080fd5b505af11580156105e9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061060d9190810190610d3d565b60608301525b7f349fc08071558d8e3aa92dec9396e4e9f2dfecd6bb9065759d1932e7da43b8a9818a846020015185606001518c8c60405161065496959493929190610dd6565b60405180910390a1507fdc1600f3000000000000000000000000000000000000000000000000000000009150505b9695505050505050565b6040516060907fa9059cbb00000000000000000000000000000000000000000000000000000000906106c49085908590602401610e1d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152905061074d84826108ab565b50505050565b60008261075e610883565b73ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156107945750815b61079c610967565b73ffffffffffffffffffffffffffffffffffffffff166306f2bf62826040518263ffffffff1660e01b81526004016107d49190610d8e565b60206040518083038186803b1580156107ec57600080fd5b505afa158015610800573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506108249190810190610c18565b915073ffffffffffffffffffffffffffffffffffffffff821661087c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161087390610e92565b60405180910390fd5b5092915050565b73c02aaa39b223fe8d0a0e5c4f27ead9083c756cc290565b6108a682848361097f565b505050565b600060608373ffffffffffffffffffffffffffffffffffffffff16836040516108d49190610d55565b6000604051808303816000865af19150503d8060008114610911576040519150601f19603f3d011682016040523d82523d6000602084013e610916565b606091505b5091509150811561095a57805161092e575050610963565b80516020141561095a576000610945826000610a56565b9050806001141561095857505050610963565b505b61074d81610a69565b5050565b73c0a47dfe034b400b47bdad5fecda2621de6c4d9590565b6040517fdd62ed3e000000000000000000000000000000000000000000000000000000008152819073ffffffffffffffffffffffffffffffffffffffff85169063dd62ed3e906109d59030908790600401610daf565b60206040518083038186803b1580156109ed57600080fd5b505afa158015610a01573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250610a259190810190610d3d565b10156108a6576108a683837fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff610a71565b6000610a628383610aa9565b9392505050565b805160208201fd5b6040516060907f095ea7b300000000000000000000000000000000000000000000000000000000906106c49085908590602401610e1d565b60008160200183511015610acf57610acf610aca6005855185602001610ad8565b610a69565b50016020015190565b6060632800659560e01b848484604051602401610af793929190610e70565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915290509392505050565b6040518060800160405280600073ffffffffffffffffffffffffffffffffffffffff16815260200160008152602001600073ffffffffffffffffffffffffffffffffffffffff168152602001600081525090565b60008083601f840112610be2578182fd5b50813567ffffffffffffffff811115610bf9578182fd5b602083019150836020828501011115610c1157600080fd5b9250929050565b600060208284031215610c29578081fd5b8151610a6281610f55565b600060208284031215610c45578081fd5b8135610a6281610f55565b60008060008060008060a08789031215610c68578182fd5b8635610c7381610f55565b95506020870135610c8381610f55565b94506040870135610c9381610f55565b935060608701359250608087013567ffffffffffffffff811115610cb5578283fd5b610cc189828a01610bd1565b979a9699509497509295939492505050565b600060208284031215610ce4578081fd5b81518015158114610a62578182fd5b600080600060408486031215610d07578283fd5b83359250602084013567ffffffffffffffff811115610d24578283fd5b610d3086828701610bd1565b9497909650939450505050565b600060208284031215610d4e578081fd5b5051919050565b60008251815b81811015610d755760208186018101518583015201610d5b565b81811115610d835782828501525b509190910192915050565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b73ffffffffffffffffffffffffffffffffffffffff92831681529116602082015260400190565b73ffffffffffffffffffffffffffffffffffffffff96871681529486166020860152604085019390935260608401919091528316608083015290911660a082015260c00190565b73ffffffffffffffffffffffffffffffffffffffff929092168252602082015260400190565b7fffffffff0000000000000000000000000000000000000000000000000000000091909116815260200190565b6060810160088510610e7e57fe5b938152602081019290925260409091015290565b6020808252601d908201527f4e4f5f554e49535741505f45584348414e47455f464f525f544f4b454e000000604082015260600190565b90815260200190565b928352602083019190915273ffffffffffffffffffffffffffffffffffffffff16604082015260600190565b95865260208601949094526040850192909252606084015273ffffffffffffffffffffffffffffffffffffffff90811660808401521660a082015260c00190565b9283526020830191909152604082015260600190565b73ffffffffffffffffffffffffffffffffffffffff81168114610f7757600080fd5b5056fea365627a7a7231582022afd1a7f0bd852b2a907eac59d84282d622a65993689c446c07cb00cc7388bd6c6578706572696d656e74616cf564736f6c63430005110040",
                "opcodes": "PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x4 CALLDATASIZE LT PUSH2 0x29 JUMPI PUSH1 0x0 CALLDATALOAD PUSH1 0xE0 SHR DUP1 PUSH4 0x1626BA7E EQ PUSH2 0x2B JUMPI DUP1 PUSH4 0xC2DF82E6 EQ PUSH2 0x61 JUMPI JUMPDEST STOP JUMPDEST CALLVALUE DUP1 ISZERO PUSH2 0x37 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH2 0x4B PUSH2 0x46 CALLDATASIZE PUSH1 0x4 PUSH2 0xCF3 JUMP JUMPDEST PUSH2 0x81 JUMP JUMPDEST PUSH1 0x40 MLOAD PUSH2 0x58 SWAP2 SWAP1 PUSH2 0xE43 JUMP JUMPDEST PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 RETURN JUMPDEST CALLVALUE DUP1 ISZERO PUSH2 0x6D JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH2 0x4B PUSH2 0x7C CALLDATASIZE PUSH1 0x4 PUSH2 0xC50 JUMP JUMPDEST PUSH2 0xA9 JUMP JUMPDEST PUSH32 0xB067138100000000000000000000000000000000000000000000000000000000 SWAP4 SWAP3 POP POP POP JUMP JUMPDEST PUSH1 0x0 PUSH2 0xB3 PUSH2 0xB7D JUMP JUMPDEST PUSH1 0x0 PUSH2 0xC1 DUP5 DUP7 ADD DUP7 PUSH2 0xC34 JUMP JUMPDEST SWAP1 POP DUP9 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP2 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND EQ ISZERO PUSH2 0x12D JUMPI PUSH2 0x102 DUP2 DUP9 DUP9 PUSH2 0x68C JUMP JUMPDEST POP PUSH32 0xDC1600F300000000000000000000000000000000000000000000000000000000 SWAP2 POP PUSH2 0x682 SWAP1 POP JUMP JUMPDEST PUSH2 0x137 DUP2 DUP11 PUSH2 0x753 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP1 DUP2 AND DUP4 MSTORE PUSH1 0x40 MLOAD PUSH32 0x70A0823100000000000000000000000000000000000000000000000000000000 DUP2 MSTORE SWAP1 DUP3 AND SWAP1 PUSH4 0x70A08231 SWAP1 PUSH2 0x18F SWAP1 ADDRESS SWAP1 PUSH1 0x4 ADD PUSH2 0xD8E JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x1A7 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x1BB JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x1DF SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xD3D JUMP JUMPDEST PUSH1 0x20 DUP4 ADD MSTORE PUSH2 0x1EC PUSH2 0x883 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP1 DUP2 AND PUSH1 0x40 DUP5 ADD DUP2 SWAP1 MSTORE SWAP1 DUP3 AND EQ ISZERO PUSH2 0x342 JUMPI DUP2 PUSH1 0x40 ADD MLOAD PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH4 0x2E1A7D4D DUP4 PUSH1 0x20 ADD MLOAD PUSH1 0x40 MLOAD DUP3 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH2 0x255 SWAP2 SWAP1 PUSH2 0xEC9 JUMP JUMPDEST PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x26F JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x283 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP DUP4 MLOAD PUSH1 0x20 DUP6 ADD MLOAD PUSH1 0x40 MLOAD PUSH32 0xAD65D76D00000000000000000000000000000000000000000000000000000000 DUP2 MSTORE PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP1 SWAP3 AND SWAP4 POP PUSH4 0xAD65D76D SWAP3 POP SWAP1 PUSH2 0x2E6 SWAP1 DUP11 SWAP1 TIMESTAMP SWAP1 DUP14 SWAP1 PUSH1 0x4 ADD PUSH2 0xED2 JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP6 DUP9 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x2FF JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x313 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x338 SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xD3D JUMP JUMPDEST PUSH1 0x60 DUP4 ADD MSTORE PUSH2 0x613 JUMP JUMPDEST DUP2 PUSH1 0x40 ADD MLOAD PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP10 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND EQ ISZERO PUSH2 0x55C JUMPI PUSH2 0x38D DUP3 PUSH1 0x0 ADD MLOAD DUP3 DUP5 PUSH1 0x20 ADD MLOAD PUSH2 0x89B JUMP JUMPDEST DUP2 MLOAD PUSH1 0x20 DUP4 ADD MLOAD PUSH1 0x40 MLOAD PUSH32 0x95E3C50B00000000000000000000000000000000000000000000000000000000 DUP2 MSTORE PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP1 SWAP3 AND SWAP2 PUSH4 0x95E3C50B SWAP2 PUSH2 0x3E9 SWAP2 DUP11 SWAP1 TIMESTAMP SWAP1 PUSH1 0x4 ADD PUSH2 0xF3F JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x403 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x417 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x43B SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xD3D JUMP JUMPDEST DUP3 PUSH1 0x60 ADD DUP2 DUP2 MSTORE POP POP DUP2 PUSH1 0x40 ADD MLOAD PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH4 0xD0E30DB0 DUP4 PUSH1 0x60 ADD MLOAD PUSH1 0x40 MLOAD DUP3 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP6 DUP9 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x494 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x4A8 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP PUSH1 0x60 DUP5 ADD MLOAD PUSH1 0x40 MLOAD PUSH32 0xA9059CBB00000000000000000000000000000000000000000000000000000000 DUP2 MSTORE PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF DUP14 AND SWAP4 POP PUSH4 0xA9059CBB SWAP3 POP PUSH2 0x504 SWAP2 DUP12 SWAP2 PUSH1 0x4 ADD PUSH2 0xE1D JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x51E JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x532 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x556 SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xCD3 JUMP JUMPDEST POP PUSH2 0x613 JUMP JUMPDEST PUSH2 0x56F DUP3 PUSH1 0x0 ADD MLOAD DUP3 DUP5 PUSH1 0x20 ADD MLOAD PUSH2 0x89B JUMP JUMPDEST DUP2 PUSH1 0x0 ADD MLOAD PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH4 0xF552D91B DUP4 PUSH1 0x20 ADD MLOAD DUP9 PUSH1 0x1 TIMESTAMP DUP13 DUP16 PUSH1 0x40 MLOAD DUP8 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH2 0x5BB SWAP7 SWAP6 SWAP5 SWAP4 SWAP3 SWAP2 SWAP1 PUSH2 0xEFE JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x5D5 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x5E9 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x60D SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xD3D JUMP JUMPDEST PUSH1 0x60 DUP4 ADD MSTORE JUMPDEST PUSH32 0x349FC08071558D8E3AA92DEC9396E4E9F2DFECD6BB9065759D1932E7DA43B8A9 DUP2 DUP11 DUP5 PUSH1 0x20 ADD MLOAD DUP6 PUSH1 0x60 ADD MLOAD DUP13 DUP13 PUSH1 0x40 MLOAD PUSH2 0x654 SWAP7 SWAP6 SWAP5 SWAP4 SWAP3 SWAP2 SWAP1 PUSH2 0xDD6 JUMP JUMPDEST PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 LOG1 POP PUSH32 0xDC1600F300000000000000000000000000000000000000000000000000000000 SWAP2 POP POP JUMPDEST SWAP7 SWAP6 POP POP POP POP POP POP JUMP JUMPDEST PUSH1 0x40 MLOAD PUSH1 0x60 SWAP1 PUSH32 0xA9059CBB00000000000000000000000000000000000000000000000000000000 SWAP1 PUSH2 0x6C4 SWAP1 DUP6 SWAP1 DUP6 SWAP1 PUSH1 0x24 ADD PUSH2 0xE1D JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH32 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFE0 DUP2 DUP5 SUB ADD DUP2 MSTORE SWAP2 SWAP1 MSTORE PUSH1 0x20 DUP2 ADD DUP1 MLOAD PUSH28 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH32 0xFFFFFFFF00000000000000000000000000000000000000000000000000000000 SWAP1 SWAP4 AND SWAP3 SWAP1 SWAP3 OR SWAP1 SWAP2 MSTORE SWAP1 POP PUSH2 0x74D DUP5 DUP3 PUSH2 0x8AB JUMP JUMPDEST POP POP POP POP JUMP JUMPDEST PUSH1 0x0 DUP3 PUSH2 0x75E PUSH2 0x883 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP5 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND EQ ISZERO PUSH2 0x794 JUMPI POP DUP2 JUMPDEST PUSH2 0x79C PUSH2 0x967 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH4 0x6F2BF62 DUP3 PUSH1 0x40 MLOAD DUP3 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH2 0x7D4 SWAP2 SWAP1 PUSH2 0xD8E JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x7EC JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x800 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0x824 SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xC18 JUMP JUMPDEST SWAP2 POP PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF DUP3 AND PUSH2 0x87C JUMPI PUSH1 0x40 MLOAD PUSH32 0x8C379A000000000000000000000000000000000000000000000000000000000 DUP2 MSTORE PUSH1 0x4 ADD PUSH2 0x873 SWAP1 PUSH2 0xE92 JUMP JUMPDEST PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST POP SWAP3 SWAP2 POP POP JUMP JUMPDEST PUSH20 0xC02AAA39B223FE8D0A0E5C4F27EAD9083C756CC2 SWAP1 JUMP JUMPDEST PUSH2 0x8A6 DUP3 DUP5 DUP4 PUSH2 0x97F JUMP JUMPDEST POP POP POP JUMP JUMPDEST PUSH1 0x0 PUSH1 0x60 DUP4 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP4 PUSH1 0x40 MLOAD PUSH2 0x8D4 SWAP2 SWAP1 PUSH2 0xD55 JUMP JUMPDEST PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP7 GAS CALL SWAP2 POP POP RETURNDATASIZE DUP1 PUSH1 0x0 DUP2 EQ PUSH2 0x911 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 0x916 JUMP JUMPDEST PUSH1 0x60 SWAP2 POP JUMPDEST POP SWAP2 POP SWAP2 POP DUP2 ISZERO PUSH2 0x95A JUMPI DUP1 MLOAD PUSH2 0x92E JUMPI POP POP PUSH2 0x963 JUMP JUMPDEST DUP1 MLOAD PUSH1 0x20 EQ ISZERO PUSH2 0x95A JUMPI PUSH1 0x0 PUSH2 0x945 DUP3 PUSH1 0x0 PUSH2 0xA56 JUMP JUMPDEST SWAP1 POP DUP1 PUSH1 0x1 EQ ISZERO PUSH2 0x958 JUMPI POP POP POP PUSH2 0x963 JUMP JUMPDEST POP JUMPDEST PUSH2 0x74D DUP2 PUSH2 0xA69 JUMP JUMPDEST POP POP JUMP JUMPDEST PUSH20 0xC0A47DFE034B400B47BDAD5FECDA2621DE6C4D95 SWAP1 JUMP JUMPDEST PUSH1 0x40 MLOAD PUSH32 0xDD62ED3E00000000000000000000000000000000000000000000000000000000 DUP2 MSTORE DUP2 SWAP1 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF DUP6 AND SWAP1 PUSH4 0xDD62ED3E SWAP1 PUSH2 0x9D5 SWAP1 ADDRESS SWAP1 DUP8 SWAP1 PUSH1 0x4 ADD PUSH2 0xDAF JUMP JUMPDEST PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x9ED JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0xA01 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x1F NOT PUSH1 0x1F DUP3 ADD AND DUP3 ADD DUP1 PUSH1 0x40 MSTORE POP PUSH2 0xA25 SWAP2 SWAP1 DUP2 ADD SWAP1 PUSH2 0xD3D JUMP JUMPDEST LT ISZERO PUSH2 0x8A6 JUMPI PUSH2 0x8A6 DUP4 DUP4 PUSH32 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF PUSH2 0xA71 JUMP JUMPDEST PUSH1 0x0 PUSH2 0xA62 DUP4 DUP4 PUSH2 0xAA9 JUMP JUMPDEST SWAP4 SWAP3 POP POP POP JUMP JUMPDEST DUP1 MLOAD PUSH1 0x20 DUP3 ADD REVERT JUMPDEST PUSH1 0x40 MLOAD PUSH1 0x60 SWAP1 PUSH32 0x95EA7B300000000000000000000000000000000000000000000000000000000 SWAP1 PUSH2 0x6C4 SWAP1 DUP6 SWAP1 DUP6 SWAP1 PUSH1 0x24 ADD PUSH2 0xE1D JUMP JUMPDEST PUSH1 0x0 DUP2 PUSH1 0x20 ADD DUP4 MLOAD LT ISZERO PUSH2 0xACF JUMPI PUSH2 0xACF PUSH2 0xACA PUSH1 0x5 DUP6 MLOAD DUP6 PUSH1 0x20 ADD PUSH2 0xAD8 JUMP JUMPDEST PUSH2 0xA69 JUMP JUMPDEST POP ADD PUSH1 0x20 ADD MLOAD SWAP1 JUMP JUMPDEST PUSH1 0x60 PUSH4 0x28006595 PUSH1 0xE0 SHL DUP5 DUP5 DUP5 PUSH1 0x40 MLOAD PUSH1 0x24 ADD PUSH2 0xAF7 SWAP4 SWAP3 SWAP2 SWAP1 PUSH2 0xE70 JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH32 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFE0 DUP2 DUP5 SUB ADD DUP2 MSTORE SWAP2 SWAP1 MSTORE PUSH1 0x20 DUP2 ADD DUP1 MLOAD PUSH28 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH32 0xFFFFFFFF00000000000000000000000000000000000000000000000000000000 SWAP1 SWAP4 AND SWAP3 SWAP1 SWAP3 OR SWAP1 SWAP2 MSTORE SWAP1 POP SWAP4 SWAP3 POP POP POP JUMP JUMPDEST PUSH1 0x40 MLOAD DUP1 PUSH1 0x80 ADD PUSH1 0x40 MSTORE DUP1 PUSH1 0x0 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP2 MSTORE PUSH1 0x20 ADD PUSH1 0x0 DUP2 MSTORE PUSH1 0x20 ADD PUSH1 0x0 PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND DUP2 MSTORE PUSH1 0x20 ADD PUSH1 0x0 DUP2 MSTORE POP SWAP1 JUMP JUMPDEST PUSH1 0x0 DUP1 DUP4 PUSH1 0x1F DUP5 ADD SLT PUSH2 0xBE2 JUMPI DUP2 DUP3 REVERT JUMPDEST POP DUP2 CALLDATALOAD PUSH8 0xFFFFFFFFFFFFFFFF DUP2 GT ISZERO PUSH2 0xBF9 JUMPI DUP2 DUP3 REVERT JUMPDEST PUSH1 0x20 DUP4 ADD SWAP2 POP DUP4 PUSH1 0x20 DUP3 DUP6 ADD ADD GT ISZERO PUSH2 0xC11 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST SWAP3 POP SWAP3 SWAP1 POP JUMP JUMPDEST PUSH1 0x0 PUSH1 0x20 DUP3 DUP5 SUB SLT ISZERO PUSH2 0xC29 JUMPI DUP1 DUP2 REVERT JUMPDEST DUP2 MLOAD PUSH2 0xA62 DUP2 PUSH2 0xF55 JUMP JUMPDEST PUSH1 0x0 PUSH1 0x20 DUP3 DUP5 SUB SLT ISZERO PUSH2 0xC45 JUMPI DUP1 DUP2 REVERT JUMPDEST DUP2 CALLDATALOAD PUSH2 0xA62 DUP2 PUSH2 0xF55 JUMP JUMPDEST PUSH1 0x0 DUP1 PUSH1 0x0 DUP1 PUSH1 0x0 DUP1 PUSH1 0xA0 DUP8 DUP10 SUB SLT ISZERO PUSH2 0xC68 JUMPI DUP2 DUP3 REVERT JUMPDEST DUP7 CALLDATALOAD PUSH2 0xC73 DUP2 PUSH2 0xF55 JUMP JUMPDEST SWAP6 POP PUSH1 0x20 DUP8 ADD CALLDATALOAD PUSH2 0xC83 DUP2 PUSH2 0xF55 JUMP JUMPDEST SWAP5 POP PUSH1 0x40 DUP8 ADD CALLDATALOAD PUSH2 0xC93 DUP2 PUSH2 0xF55 JUMP JUMPDEST SWAP4 POP PUSH1 0x60 DUP8 ADD CALLDATALOAD SWAP3 POP PUSH1 0x80 DUP8 ADD CALLDATALOAD PUSH8 0xFFFFFFFFFFFFFFFF DUP2 GT ISZERO PUSH2 0xCB5 JUMPI DUP3 DUP4 REVERT JUMPDEST PUSH2 0xCC1 DUP10 DUP3 DUP11 ADD PUSH2 0xBD1 JUMP JUMPDEST SWAP8 SWAP11 SWAP7 SWAP10 POP SWAP5 SWAP8 POP SWAP3 SWAP6 SWAP4 SWAP5 SWAP3 POP POP POP JUMP JUMPDEST PUSH1 0x0 PUSH1 0x20 DUP3 DUP5 SUB SLT ISZERO PUSH2 0xCE4 JUMPI DUP1 DUP2 REVERT JUMPDEST DUP2 MLOAD DUP1 ISZERO ISZERO DUP2 EQ PUSH2 0xA62 JUMPI DUP2 DUP3 REVERT JUMPDEST PUSH1 0x0 DUP1 PUSH1 0x0 PUSH1 0x40 DUP5 DUP7 SUB SLT ISZERO PUSH2 0xD07 JUMPI DUP3 DUP4 REVERT JUMPDEST DUP4 CALLDATALOAD SWAP3 POP PUSH1 0x20 DUP5 ADD CALLDATALOAD PUSH8 0xFFFFFFFFFFFFFFFF DUP2 GT ISZERO PUSH2 0xD24 JUMPI DUP3 DUP4 REVERT JUMPDEST PUSH2 0xD30 DUP7 DUP3 DUP8 ADD PUSH2 0xBD1 JUMP JUMPDEST SWAP5 SWAP8 SWAP1 SWAP7 POP SWAP4 SWAP5 POP POP POP POP JUMP JUMPDEST PUSH1 0x0 PUSH1 0x20 DUP3 DUP5 SUB SLT ISZERO PUSH2 0xD4E JUMPI DUP1 DUP2 REVERT JUMPDEST POP MLOAD SWAP2 SWAP1 POP JUMP JUMPDEST PUSH1 0x0 DUP3 MLOAD DUP2 JUMPDEST DUP2 DUP2 LT ISZERO PUSH2 0xD75 JUMPI PUSH1 0x20 DUP2 DUP7 ADD DUP2 ADD MLOAD DUP6 DUP4 ADD MSTORE ADD PUSH2 0xD5B JUMP JUMPDEST DUP2 DUP2 GT ISZERO PUSH2 0xD83 JUMPI DUP3 DUP3 DUP6 ADD MSTORE JUMPDEST POP SWAP2 SWAP1 SWAP2 ADD SWAP3 SWAP2 POP POP JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP2 SWAP1 SWAP2 AND DUP2 MSTORE PUSH1 0x20 ADD SWAP1 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP3 DUP4 AND DUP2 MSTORE SWAP2 AND PUSH1 0x20 DUP3 ADD MSTORE PUSH1 0x40 ADD SWAP1 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP7 DUP8 AND DUP2 MSTORE SWAP5 DUP7 AND PUSH1 0x20 DUP7 ADD MSTORE PUSH1 0x40 DUP6 ADD SWAP4 SWAP1 SWAP4 MSTORE PUSH1 0x60 DUP5 ADD SWAP2 SWAP1 SWAP2 MSTORE DUP4 AND PUSH1 0x80 DUP4 ADD MSTORE SWAP1 SWAP2 AND PUSH1 0xA0 DUP3 ADD MSTORE PUSH1 0xC0 ADD SWAP1 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP3 SWAP1 SWAP3 AND DUP3 MSTORE PUSH1 0x20 DUP3 ADD MSTORE PUSH1 0x40 ADD SWAP1 JUMP JUMPDEST PUSH32 0xFFFFFFFF00000000000000000000000000000000000000000000000000000000 SWAP2 SWAP1 SWAP2 AND DUP2 MSTORE PUSH1 0x20 ADD SWAP1 JUMP JUMPDEST PUSH1 0x60 DUP2 ADD PUSH1 0x8 DUP6 LT PUSH2 0xE7E JUMPI INVALID JUMPDEST SWAP4 DUP2 MSTORE PUSH1 0x20 DUP2 ADD SWAP3 SWAP1 SWAP3 MSTORE PUSH1 0x40 SWAP1 SWAP2 ADD MSTORE SWAP1 JUMP JUMPDEST PUSH1 0x20 DUP1 DUP3 MSTORE PUSH1 0x1D SWAP1 DUP3 ADD MSTORE PUSH32 0x4E4F5F554E49535741505F45584348414E47455F464F525F544F4B454E000000 PUSH1 0x40 DUP3 ADD MSTORE PUSH1 0x60 ADD SWAP1 JUMP JUMPDEST SWAP1 DUP2 MSTORE PUSH1 0x20 ADD SWAP1 JUMP JUMPDEST SWAP3 DUP4 MSTORE PUSH1 0x20 DUP4 ADD SWAP2 SWAP1 SWAP2 MSTORE PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF AND PUSH1 0x40 DUP3 ADD MSTORE PUSH1 0x60 ADD SWAP1 JUMP JUMPDEST SWAP6 DUP7 MSTORE PUSH1 0x20 DUP7 ADD SWAP5 SWAP1 SWAP5 MSTORE PUSH1 0x40 DUP6 ADD SWAP3 SWAP1 SWAP3 MSTORE PUSH1 0x60 DUP5 ADD MSTORE PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF SWAP1 DUP2 AND PUSH1 0x80 DUP5 ADD MSTORE AND PUSH1 0xA0 DUP3 ADD MSTORE PUSH1 0xC0 ADD SWAP1 JUMP JUMPDEST SWAP3 DUP4 MSTORE PUSH1 0x20 DUP4 ADD SWAP2 SWAP1 SWAP2 MSTORE PUSH1 0x40 DUP3 ADD MSTORE PUSH1 0x60 ADD SWAP1 JUMP JUMPDEST PUSH20 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF DUP2 AND DUP2 EQ PUSH2 0xF77 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP JUMP INVALID LOG3 PUSH6 0x627A7A723158 KECCAK256 0x22 0xAF 0xD1 0xA7 CREATE 0xBD DUP6 0x2B 0x2A SWAP1 PUSH31 0xAC59D84282D622A65993689C446C07CB00CC7388BD6C6578706572696D656E PUSH21 0x616CF564736F6C6343000511004000000000000000 ",
                "sourceMap": "1188:6843:27:-;;;;;;;;;;;;;;;;;;;;;;;;6092:192;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;6092:192:27;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;2259:3633;;8:9:-1;5:2;;;30:1;27;20:12;5:2;-1:-1;2259:3633:27;;;;;;;;:::i;6092:192::-;6252:25;6092:192;;;;;:::o;2259:3633::-;2460:14;2547:26;;:::i;:::-;2649:24;2677:33;;;;2688:10;2677:33;;;2648:62;;2802:14;2782:34;;:16;:34;;;2778:152;;;2832:52;2855:16;2873:2;2877:6;2832:22;:52::i;:::-;-1:-1:-1;2905:14:27;;-1:-1:-1;2898:21:27;;-1:-1:-1;2898:21:27;2778:152;3005:99;3050:16;3080:14;3005:31;:99::i;:::-;2988:116;;;;;;3195:54;;;;;:39;;;;;;:54;;3243:4;;3195:54;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3195:54:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3195:54:27;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;3195:54:27;;;;;;;;;3170:22;;;:79;3318:17;:15;:17::i;:::-;3293:43;;;;:10;;;:43;;;3392:39;;;;3388:2262;;;3479:5;:10;;;:19;;;3499:5;:22;;;3479:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3479:43:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;-1:-1;;3671:14:27;;3716:22;;;;3671:281;;;;;:38;;;;;-1:-1:-1;3671:38:27;;-1:-1:-1;3716:22:27;3671:281;;3796:6;;3865:15;;3936:2;;3671:281;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3671:281:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3671:281:27;;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;3671:281:27;;;;;;;;;3650:18;;;:302;3388:2262;;;4041:5;:10;;;4015:37;;:14;:37;;;4011:1639;;;4116:81;4140:5;:14;;;4156:16;4174:5;:22;;;4116:23;:81::i;:::-;4306:14;;4402:22;;;;4306:273;;;;;:34;;;;;;;:273;;4481:6;;4550:15;;4306:273;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4306:273:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4306:273:27;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;4306:273:27;;;;;;;;;4285:5;:18;;:294;;;;;4622:5;:10;;;:18;;;4647:5;:18;;;4622:46;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4622:46:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;-1:-1;;;4765:18:27;;;;4724:60;;;;;:36;;;;-1:-1:-1;4724:36:27;;-1:-1:-1;4724:60:27;;4761:2;;4724:60;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4724:60:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4724:60:27;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;4724:60:27;;;;;;;;;;4011:1639;;;4910:81;4934:5;:14;;;4950:16;4968:5;:22;;;4910:23;:81::i;:::-;5146:5;:14;;;:40;;;5248:5;:22;;;5327:6;5408:1;5472:15;5543:2;5611:14;5146:493;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5146:493:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5146:493:27;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;5146:493:27;;;;;;;;;5125:18;;;:514;4011:1639;5665:189;5698:16;5728:14;5756:5;:22;;;5792:5;:18;;;5824:4;5842:2;5665:189;;;;;;;;;;;;;;;;;;;;-1:-1:-1;5871:14:27;;-1:-1:-1;;2259:3633:27;;;;;;;;;:::o;2581:324:61:-;2727:114;;2703:21;;2763:32;;2727:114;;2809:2;;2825:6;;2727:114;;;;;;;;22:32:-1;26:21;;;22:32;6:49;;2727:114:61;;;49:4:-1;25:18;;61:17;;2727:114:61;182:15:-1;2727:114:61;;;;179:29:-1;;;;160:49;;;2727:114:61;-1:-1:-1;2851:47:61;2882:5;2727:114;2851:30;:47::i;:::-;2581:324;;;;:::o;7330:699:27:-;7489:25;7561:16;7666:17;:15;:17::i;:::-;7646:37;;:16;:37;;;7642:105;;;-1:-1:-1;7722:14:27;7642:105;7821:35;:33;:35::i;:::-;7797:85;;;7883:20;7797:107;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7797:107:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7797:107:27;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;7797:107:27;;;;;;;;;7756:158;-1:-1:-1;7932:31:27;;;7924:73;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;7330:699:27;;;;:::o;10548:135:68:-;871:42;10548:135;:::o;6585:300:27:-;6753:125;6795:12;6829:8;6852:16;6753:28;:125::i;:::-;6585:300;;;:::o;6120:571:61:-;6252:15;6269:23;6296:6;:11;;6308:8;6296:21;;;;;;;;;;;;;;;;;;;;;;;14:1:-1;21;16:31;;;;75:4;69:11;64:16;;144:4;140:9;133:4;115:16;111:27;107:43;104:1;100:51;94:4;87:65;169:16;166:1;159:27;225:16;222:1;215:4;212:1;208:12;193:49;7:242;;16:31;36:4;31:9;;7:242;;6251:66:61;;;;6331:10;6327:315;;;6361:17;;6357:67;;6403:7;;;;6357:67;6441:10;:17;6462:2;6441:23;6437:195;;;6484:14;6501:35;6522:10;6534:1;6501:20;:35::i;:::-;6484:52;;6558:6;6568:1;6558:11;6554:64;;;6593:7;;;;;6554:64;6437:195;;6651:33;6673:10;6651:21;:33::i;6120:571::-;;;:::o;10832:176:68:-;1382:42;10832:176;:::o;1978:267:61:-;2115:52;;;;;2170:6;;2115:28;;;;;;:52;;2152:4;;2159:7;;2115:52;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2115:52:61;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2115:52:61;;;;;;;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;2115:52:61;;;;;;;;;:61;2111:128;;;2192:36;2200:5;2207:7;2224:2;2192:7;:36::i;15929:220:72:-;16050:14;16097:21;16109:1;16112:5;16097:11;:21::i;:::-;16089:30;15929:220;-1:-1:-1;;;15929:220:72:o;1511:170:75:-;1654:9;1648:16;1641:4;1630:9;1626:20;1619:46;1194:338:61;1347:121;;1323:21;;1383:31;;1347:121;;1428:7;;1449:9;;1347:121;;;;14133:679:72;14254:14;14299:5;14307:2;14299:10;14288:1;:8;:21;14284:297;;;14325:245;14347:222;14409:92;14519:1;:8;14545:5;14553:2;14545:10;14347:44;:222::i;:::-;14325:21;:245::i;:::-;-1:-1:-1;14759:13:72;14661:2;14759:13;14753:20;;14133:679::o;1292:378:73:-;1480:12;1232:10;1551:37;;1602:9;1625:6;1645:8;1515:148;;;;;;;;;;;;;;;22:32:-1;26:21;;;22:32;6:49;;1515:148:73;;;49:4:-1;25:18;;61:17;;1515:148:73;182:15:-1;1515:148:73;;;;179:29:-1;;;;160:49;;;1515:148:73;-1:-1:-1;1292:378:73;;;;;:::o;1188:6843:27:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;722:336:-1:-;;;836:3;829:4;821:6;817:17;813:27;803:2;;-1:-1;;844:12;803:2;-1:-1;874:20;;914:18;903:30;;900:2;;;-1:-1;;936:12;900:2;980:4;972:6;968:17;956:29;;1031:3;980:4;1011:17;972:6;997:32;;994:41;991:2;;;1048:1;;1038:12;991:2;796:262;;;;;;1344:263;;1459:2;1447:9;1438:7;1434:23;1430:32;1427:2;;;-1:-1;;1465:12;1427:2;226:6;220:13;238:33;265:5;238:33;;1614:257;;1726:2;1714:9;1705:7;1701:23;1697:32;1694:2;;;-1:-1;;1732:12;1694:2;371:6;358:20;383:41;418:5;383:41;;1878:867;;;;;;;2069:3;2057:9;2048:7;2044:23;2040:33;2037:2;;;-1:-1;;2076:12;2037:2;85:6;72:20;97:33;124:5;97:33;;;2128:63;-1:-1;2228:2;2267:22;;72:20;97:33;72:20;97:33;;;2236:63;-1:-1;2336:2;2375:22;;72:20;97:33;72:20;97:33;;;2344:63;-1:-1;2444:2;2483:22;;1133:20;;-1:-1;2580:3;2565:19;;2552:33;2605:18;2594:30;;2591:2;;;-1:-1;;2627:12;2591:2;2665:64;2721:7;2712:6;2701:9;2697:22;2665:64;;;2031:714;;;;-1:-1;2031:714;;-1:-1;2031:714;;2655:74;;2031:714;-1:-1;;;2031:714;2752:257;;2864:2;2852:9;2843:7;2839:23;2835:32;2832:2;;;-1:-1;;2870:12;2832:2;517:6;511:13;13357:5;11266:13;11259:21;13335:5;13332:32;13322:2;;-1:-1;;13368:12;3016:490;;;;3156:2;3144:9;3135:7;3131:23;3127:32;3124:2;;;-1:-1;;3162:12;3124:2;651:6;638:20;3214:63;;3342:2;3331:9;3327:18;3314:32;3366:18;3358:6;3355:30;3352:2;;;-1:-1;;3388:12;3352:2;3426:64;3482:7;3473:6;3462:9;3458:22;3426:64;;;3118:388;;3416:74;;-1:-1;3416:74;;-1:-1;;;;3118:388;3513:263;;3628:2;3616:9;3607:7;3603:23;3599:32;3596:2;;;-1:-1;;3634:12;3596:2;-1:-1;1281:13;;3590:186;-1:-1;3590:186;5340:262;;4329:5;10630:12;-1:-1;12674:101;12688:6;12685:1;12682:13;12674:101;;;4473:4;12755:11;;;;;12749:18;12736:11;;;12729:39;12703:10;12674:101;;;12790:6;12787:1;12784:13;12781:2;;;-1:-1;12846:6;12841:3;12837:16;12830:27;12781:2;-1:-1;4504:16;;;;;5465:137;-1:-1;;5465:137;5609:213;11780:42;11769:54;;;;4003:37;;5727:2;5712:18;;5698:124;6065:324;11780:42;11769:54;;;4003:37;;11769:54;;6375:2;6360:18;;4003:37;6211:2;6196:18;;6182:207;6396:771;11780:42;11769:54;;;4003:37;;11769:54;;;6819:2;6804:18;;4003:37;6902:2;6887:18;;5291:37;;;;6985:2;6970:18;;5291:37;;;;11769:54;;7068:3;7053:19;;4003:37;11769:54;;;7152:3;7137:19;;4003:37;6654:3;6639:19;;6625:542;7174:324;11780:42;11769:54;;;;4003:37;;7484:2;7469:18;;5291:37;7320:2;7305:18;;7291:207;7505:209;11443:66;11432:78;;;;4121:36;;7621:2;7606:18;;7592:122;7721:503;7929:2;7914:18;;12983:1;12973:12;;12963:2;;12989:9;12963:2;4637:84;;;8127:2;8112:18;;5291:37;;;;8210:2;8195:18;;;5291:37;7900:324;;8231:407;8422:2;8436:47;;;5107:2;8407:18;;;10928:19;5143:31;10968:14;;;5123:52;5194:12;;;8393:245;8645:213;5291:37;;;8763:2;8748:18;;8734:124;8865:435;5291:37;;;9203:2;9188:18;;5291:37;;;;11780:42;11769:54;9286:2;9271:18;;4003:37;9039:2;9024:18;;9010:290;9307:787;5291:37;;;9738:2;9723:18;;5291:37;;;;9829:2;9814:18;;4812:58;;;;9912:2;9897:18;;5291:37;11780:42;11769:54;;;9995:3;9980:19;;4003:37;11769:54;10079:3;10064:19;;4003:37;9573:3;9558:19;;9544:550;10101:435;5291:37;;;10439:2;10424:18;;5291:37;;;;10522:2;10507:18;;5291:37;10275:2;10260:18;;10246:290;13012:117;11780:42;13099:5;11769:54;13074:5;13071:35;13061:2;;13120:1;;13110:12;13061:2;13055:74;"
            }
        }
    },
    "sourceTreeHashHex": "0x5ab0bfac540cc1505ec64892fb98d7bf80fde66f21936dbf0e845f0edb2a4ea2",
    "sources": {
        "./UniswapBridge.sol": {
            "id": 27,
            "content": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\npragma experimental ABIEncoderV2;\n\nimport \"@0x/contracts-erc20/contracts/src/interfaces/IERC20Token.sol\";\nimport \"@0x/contracts-erc20/contracts/src/interfaces/IEtherToken.sol\";\nimport \"@0x/contracts-erc20/contracts/src/LibERC20Token.sol\";\nimport \"@0x/contracts-exchange-libs/contracts/src/IWallet.sol\";\nimport \"@0x/contracts-utils/contracts/src/DeploymentConstants.sol\";\nimport \"../interfaces/IUniswapExchangeFactory.sol\";\nimport \"../interfaces/IUniswapExchange.sol\";\nimport \"../interfaces/IERC20Bridge.sol\";\n\n\n// solhint-disable space-after-comma\n// solhint-disable not-rely-on-time\ncontract UniswapBridge is\n    IERC20Bridge,\n    IWallet,\n    DeploymentConstants\n{\n    // Struct to hold `bridgeTransferFrom()` local variables in memory and to avoid\n    // stack overflows.\n    struct TransferState {\n        IUniswapExchange exchange;\n        uint256 fromTokenBalance;\n        IEtherToken weth;\n        uint256 boughtAmount;\n    }\n\n    // solhint-disable no-empty-blocks\n    /// @dev Payable fallback to receive ETH from uniswap.\n    function ()\n        external\n        payable\n    {}\n\n    /// @dev Callback for `IERC20Bridge`. Tries to buy `amount` of\n    ///      `toTokenAddress` tokens by selling the entirety of the `fromTokenAddress`\n    ///      token encoded in the bridge data.\n    /// @param toTokenAddress The token to buy and transfer to `to`.\n    /// @param from The maker (this contract).\n    /// @param to The recipient of the bought tokens.\n    /// @param amount Minimum amount of `toTokenAddress` tokens to buy.\n    /// @param bridgeData The abi-encoded \"from\" token address.\n    /// @return success The magic bytes if successful.\n    function bridgeTransferFrom(\n        address toTokenAddress,\n        address from,\n        address to,\n        uint256 amount,\n        bytes calldata bridgeData\n    )\n        external\n        returns (bytes4 success)\n    {\n        // State memory object to avoid stack overflows.\n        TransferState memory state;\n        // Decode the bridge data to get the `fromTokenAddress`.\n        (address fromTokenAddress) = abi.decode(bridgeData, (address));\n\n        // Just transfer the tokens if they're the same.\n        if (fromTokenAddress == toTokenAddress) {\n            LibERC20Token.transfer(fromTokenAddress, to, amount);\n            return BRIDGE_SUCCESS;\n        }\n\n        // Get the exchange for the token pair.\n        state.exchange = _getUniswapExchangeForTokenPair(\n            fromTokenAddress,\n            toTokenAddress\n        );\n        // Get our balance of `fromTokenAddress` token.\n        state.fromTokenBalance = IERC20Token(fromTokenAddress).balanceOf(address(this));\n        // Get the weth contract.\n        state.weth = IEtherToken(_getWethAddress());\n\n        // Convert from WETH to a token.\n        if (fromTokenAddress == address(state.weth)) {\n            // Unwrap the WETH.\n            state.weth.withdraw(state.fromTokenBalance);\n            // Buy as much of `toTokenAddress` token with ETH as possible and\n            // transfer it to `to`.\n            state.boughtAmount = state.exchange.ethToTokenTransferInput.value(state.fromTokenBalance)(\n                // Minimum buy amount.\n                amount,\n                // Expires after this block.\n                block.timestamp,\n                // Recipient is `to`.\n                to\n            );\n\n        // Convert from a token to WETH.\n        } else if (toTokenAddress == address(state.weth)) {\n            // Grant the exchange an allowance.\n            _grantExchangeAllowance(state.exchange, fromTokenAddress, state.fromTokenBalance);\n            // Buy as much ETH with `fromTokenAddress` token as possible.\n            state.boughtAmount = state.exchange.tokenToEthSwapInput(\n                // Sell all tokens we hold.\n                state.fromTokenBalance,\n                // Minimum buy amount.\n                amount,\n                // Expires after this block.\n                block.timestamp\n            );\n            // Wrap the ETH.\n            state.weth.deposit.value(state.boughtAmount)();\n            // Transfer the WETH to `to`.\n            IEtherToken(toTokenAddress).transfer(to, state.boughtAmount);\n\n        // Convert from one token to another.\n        } else {\n            // Grant the exchange an allowance.\n            _grantExchangeAllowance(state.exchange, fromTokenAddress, state.fromTokenBalance);\n            // Buy as much `toTokenAddress` token with `fromTokenAddress` token\n            // and transfer it to `to`.\n            state.boughtAmount = state.exchange.tokenToTokenTransferInput(\n                // Sell all tokens we hold.\n                state.fromTokenBalance,\n                // Minimum buy amount.\n                amount,\n                // Must buy at least 1 intermediate ETH.\n                1,\n                // Expires after this block.\n                block.timestamp,\n                // Recipient is `to`.\n                to,\n                // Convert to `toTokenAddress`.\n                toTokenAddress\n            );\n        }\n\n        emit ERC20BridgeTransfer(\n            fromTokenAddress,\n            toTokenAddress,\n            state.fromTokenBalance,\n            state.boughtAmount,\n            from,\n            to\n        );\n        return BRIDGE_SUCCESS;\n    }\n\n    /// @dev `SignatureType.Wallet` callback, so that this bridge can be the maker\n    ///      and sign for itself in orders. Always succeeds.\n    /// @return magicValue Success bytes, always.\n    function isValidSignature(\n        bytes32,\n        bytes calldata\n    )\n        external\n        view\n        returns (bytes4 magicValue)\n    {\n        return LEGACY_WALLET_MAGIC_VALUE;\n    }\n\n    /// @dev Grants an unlimited allowance to the exchange for its token\n    ///      on behalf of this contract.\n    /// @param exchange The Uniswap token exchange.\n    /// @param tokenAddress The token address for the exchange.\n    /// @param minimumAllowance The minimum necessary allowance.\n    function _grantExchangeAllowance(\n        IUniswapExchange exchange,\n        address tokenAddress,\n        uint256 minimumAllowance\n    )\n        private\n    {\n        LibERC20Token.approveIfBelow(\n            tokenAddress,\n            address(exchange),\n            minimumAllowance\n        );\n    }\n\n    /// @dev Retrieves the uniswap exchange for a given token pair.\n    ///      In the case of a WETH-token exchange, this will be the non-WETH token.\n    ///      In th ecase of a token-token exchange, this will be the first token.\n    /// @param fromTokenAddress The address of the token we are converting from.\n    /// @param toTokenAddress The address of the token we are converting to.\n    /// @return exchange The uniswap exchange.\n    function _getUniswapExchangeForTokenPair(\n        address fromTokenAddress,\n        address toTokenAddress\n    )\n        private\n        view\n        returns (IUniswapExchange exchange)\n    {\n        address exchangeTokenAddress = fromTokenAddress;\n        // Whichever isn't WETH is the exchange token.\n        if (fromTokenAddress == _getWethAddress()) {\n            exchangeTokenAddress = toTokenAddress;\n        }\n        exchange = IUniswapExchange(\n            IUniswapExchangeFactory(_getUniswapExchangeFactoryAddress())\n            .getExchange(exchangeTokenAddress)\n        );\n        require(address(exchange) != address(0), \"NO_UNISWAP_EXCHANGE_FOR_TOKEN\");\n        return exchange;\n    }\n}\n"
        },
        "@0x/contracts-erc20/contracts/src/interfaces/IERC20Token.sol": {
            "id": 62,
            "content": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\ncontract IERC20Token {\n\n    // solhint-disable no-simple-event-func-name\n    event Transfer(\n        address indexed _from,\n        address indexed _to,\n        uint256 _value\n    );\n\n    event Approval(\n        address indexed _owner,\n        address indexed _spender,\n        uint256 _value\n    );\n\n    /// @dev send `value` token to `to` from `msg.sender`\n    /// @param _to The address of the recipient\n    /// @param _value The amount of token to be transferred\n    /// @return True if transfer was successful\n    function transfer(address _to, uint256 _value)\n        external\n        returns (bool);\n\n    /// @dev send `value` token to `to` from `from` on the condition it is approved by `from`\n    /// @param _from The address of the sender\n    /// @param _to The address of the recipient\n    /// @param _value The amount of token to be transferred\n    /// @return True if transfer was successful\n    function transferFrom(\n        address _from,\n        address _to,\n        uint256 _value\n    )\n        external\n        returns (bool);\n\n    /// @dev `msg.sender` approves `_spender` to spend `_value` tokens\n    /// @param _spender The address of the account able to transfer the tokens\n    /// @param _value The amount of wei to be approved for transfer\n    /// @return Always true if the call has enough gas to complete execution\n    function approve(address _spender, uint256 _value)\n        external\n        returns (bool);\n\n    /// @dev Query total supply of token\n    /// @return Total supply of token\n    function totalSupply()\n        external\n        view\n        returns (uint256);\n\n    /// @param _owner The address from which the balance will be retrieved\n    /// @return Balance of owner\n    function balanceOf(address _owner)\n        external\n        view\n        returns (uint256);\n\n    /// @param _owner The address of the account owning tokens\n    /// @param _spender The address of the account able to transfer the tokens\n    /// @return Amount of remaining tokens allowed to spent\n    function allowance(address _owner, address _spender)\n        external\n        view\n        returns (uint256);\n}\n"
        },
        "@0x/contracts-erc20/contracts/src/interfaces/IEtherToken.sol": {
            "id": 63,
            "content": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\nimport \"./IERC20Token.sol\";\n\n\ncontract IEtherToken is\n    IERC20Token\n{\n    function deposit()\n        public\n        payable;\n    \n    function withdraw(uint256 amount)\n        public;\n}\n"
        },
        "@0x/contracts-erc20/contracts/src/LibERC20Token.sol": {
            "id": 61,
            "content": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\nimport \"@0x/contracts-utils/contracts/src/LibRichErrors.sol\";\nimport \"@0x/contracts-utils/contracts/src/LibBytes.sol\";\nimport \"../src/interfaces/IERC20Token.sol\";\n\n\nlibrary LibERC20Token {\n    bytes constant private DECIMALS_CALL_DATA = hex\"313ce567\";\n\n    /// @dev Calls `IERC20Token(token).approve()`.\n    ///      Reverts if `false` is returned or if the return\n    ///      data length is nonzero and not 32 bytes.\n    /// @param token The address of the token contract.\n    /// @param spender The address that receives an allowance.\n    /// @param allowance The allowance to set.\n    function approve(\n        address token,\n        address spender,\n        uint256 allowance\n    )\n        internal\n    {\n        bytes memory callData = abi.encodeWithSelector(\n            IERC20Token(0).approve.selector,\n            spender,\n            allowance\n        );\n        _callWithOptionalBooleanResult(token, callData);\n    }\n\n    /// @dev Calls `IERC20Token(token).approve()` and sets the allowance to the\n    ///      maximum if the current approval is not already >= an amount.\n    ///      Reverts if `false` is returned or if the return\n    ///      data length is nonzero and not 32 bytes.\n    /// @param token The address of the token contract.\n    /// @param spender The address that receives an allowance.\n    /// @param amount The minimum allowance needed.\n    function approveIfBelow(\n        address token,\n        address spender,\n        uint256 amount\n    )\n        internal\n    {\n        if (IERC20Token(token).allowance(address(this), spender) < amount) {\n            approve(token, spender, uint256(-1));\n        }\n    }\n\n    /// @dev Calls `IERC20Token(token).transfer()`.\n    ///      Reverts if `false` is returned or if the return\n    ///      data length is nonzero and not 32 bytes.\n    /// @param token The address of the token contract.\n    /// @param to The address that receives the tokens\n    /// @param amount Number of tokens to transfer.\n    function transfer(\n        address token,\n        address to,\n        uint256 amount\n    )\n        internal\n    {\n        bytes memory callData = abi.encodeWithSelector(\n            IERC20Token(0).transfer.selector,\n            to,\n            amount\n        );\n        _callWithOptionalBooleanResult(token, callData);\n    }\n\n    /// @dev Calls `IERC20Token(token).transferFrom()`.\n    ///      Reverts if `false` is returned or if the return\n    ///      data length is nonzero and not 32 bytes.\n    /// @param token The address of the token contract.\n    /// @param from The owner of the tokens.\n    /// @param to The address that receives the tokens\n    /// @param amount Number of tokens to transfer.\n    function transferFrom(\n        address token,\n        address from,\n        address to,\n        uint256 amount\n    )\n        internal\n    {\n        bytes memory callData = abi.encodeWithSelector(\n            IERC20Token(0).transferFrom.selector,\n            from,\n            to,\n            amount\n        );\n        _callWithOptionalBooleanResult(token, callData);\n    }\n\n    /// @dev Retrieves the number of decimals for a token.\n    ///      Returns `18` if the call reverts.\n    /// @param token The address of the token contract.\n    /// @return tokenDecimals The number of decimals places for the token.\n    function decimals(address token)\n        internal\n        view\n        returns (uint8 tokenDecimals)\n    {\n        tokenDecimals = 18;\n        (bool didSucceed, bytes memory resultData) = token.staticcall(DECIMALS_CALL_DATA);\n        if (didSucceed && resultData.length == 32) {\n            tokenDecimals = uint8(LibBytes.readUint256(resultData, 0));\n        }\n    }\n\n    /// @dev Retrieves the allowance for a token, owner, and spender.\n    ///      Returns `0` if the call reverts.\n    /// @param token The address of the token contract.\n    /// @param owner The owner of the tokens.\n    /// @param spender The address the spender.\n    /// @return allowance The allowance for a token, owner, and spender.\n    function allowance(address token, address owner, address spender)\n        internal\n        view\n        returns (uint256 allowance_)\n    {\n        (bool didSucceed, bytes memory resultData) = token.staticcall(\n            abi.encodeWithSelector(\n                IERC20Token(0).allowance.selector,\n                owner,\n                spender\n            )\n        );\n        if (didSucceed && resultData.length == 32) {\n            allowance_ = LibBytes.readUint256(resultData, 0);\n        }\n    }\n\n    /// @dev Retrieves the balance for a token owner.\n    ///      Returns `0` if the call reverts.\n    /// @param token The address of the token contract.\n    /// @param owner The owner of the tokens.\n    /// @return balance The token balance of an owner.\n    function balanceOf(address token, address owner)\n        internal\n        view\n        returns (uint256 balance)\n    {\n        (bool didSucceed, bytes memory resultData) = token.staticcall(\n            abi.encodeWithSelector(\n                IERC20Token(0).balanceOf.selector,\n                owner\n            )\n        );\n        if (didSucceed && resultData.length == 32) {\n            balance = LibBytes.readUint256(resultData, 0);\n        }\n    }\n\n    /// @dev Executes a call on address `target` with calldata `callData`\n    ///      and asserts that either nothing was returned or a single boolean\n    ///      was returned equal to `true`.\n    /// @param target The call target.\n    /// @param callData The abi-encoded call data.\n    function _callWithOptionalBooleanResult(\n        address target,\n        bytes memory callData\n    )\n        private\n    {\n        (bool didSucceed, bytes memory resultData) = target.call(callData);\n        if (didSucceed) {\n            if (resultData.length == 0) {\n                return;\n            }\n            if (resultData.length == 32) {\n                uint256 result = LibBytes.readUint256(resultData, 0);\n                if (result == 1) {\n                    return;\n                }\n            }\n        }\n        LibRichErrors.rrevert(resultData);\n    }\n}\n"
        },
        "@0x/contracts-utils/contracts/src/LibRichErrors.sol": {
            "id": 75,
            "content": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\nlibrary LibRichErrors {\n\n    // bytes4(keccak256(\"Error(string)\"))\n    bytes4 internal constant STANDARD_ERROR_SELECTOR =\n        0x08c379a0;\n\n    // solhint-disable func-name-mixedcase\n    /// @dev ABI encode a standard, string revert error payload.\n    ///      This is the same payload that would be included by a `revert(string)`\n    ///      solidity statement. It has the function signature `Error(string)`.\n    /// @param message The error string.\n    /// @return The ABI encoded error.\n    function StandardError(\n        string memory message\n    )\n        internal\n        pure\n        returns (bytes memory)\n    {\n        return abi.encodeWithSelector(\n            STANDARD_ERROR_SELECTOR,\n            bytes(message)\n        );\n    }\n    // solhint-enable func-name-mixedcase\n\n    /// @dev Reverts an encoded rich revert reason `errorData`.\n    /// @param errorData ABI encoded error data.\n    function rrevert(bytes memory errorData)\n        internal\n        pure\n    {\n        assembly {\n            revert(add(errorData, 0x20), mload(errorData))\n        }\n    }\n}\n"
        },
        "@0x/contracts-utils/contracts/src/LibBytes.sol": {
            "id": 72,
            "content": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\nimport \"./LibBytesRichErrors.sol\";\nimport \"./LibRichErrors.sol\";\n\n\nlibrary LibBytes {\n\n    using LibBytes for bytes;\n\n    /// @dev Gets the memory address for a byte array.\n    /// @param input Byte array to lookup.\n    /// @return memoryAddress Memory address of byte array. This\n    ///         points to the header of the byte array which contains\n    ///         the length.\n    function rawAddress(bytes memory input)\n        internal\n        pure\n        returns (uint256 memoryAddress)\n    {\n        assembly {\n            memoryAddress := input\n        }\n        return memoryAddress;\n    }\n\n    /// @dev Gets the memory address for the contents of a byte array.\n    /// @param input Byte array to lookup.\n    /// @return memoryAddress Memory address of the contents of the byte array.\n    function contentAddress(bytes memory input)\n        internal\n        pure\n        returns (uint256 memoryAddress)\n    {\n        assembly {\n            memoryAddress := add(input, 32)\n        }\n        return memoryAddress;\n    }\n\n    /// @dev Copies `length` bytes from memory location `source` to `dest`.\n    /// @param dest memory address to copy bytes to.\n    /// @param source memory address to copy bytes from.\n    /// @param length number of bytes to copy.\n    function memCopy(\n        uint256 dest,\n        uint256 source,\n        uint256 length\n    )\n        internal\n        pure\n    {\n        if (length < 32) {\n            // Handle a partial word by reading destination and masking\n            // off the bits we are interested in.\n            // This correctly handles overlap, zero lengths and source == dest\n            assembly {\n                let mask := sub(exp(256, sub(32, length)), 1)\n                let s := and(mload(source), not(mask))\n                let d := and(mload(dest), mask)\n                mstore(dest, or(s, d))\n            }\n        } else {\n            // Skip the O(length) loop when source == dest.\n            if (source == dest) {\n                return;\n            }\n\n            // For large copies we copy whole words at a time. The final\n            // word is aligned to the end of the range (instead of after the\n            // previous) to handle partial words. So a copy will look like this:\n            //\n            //  ####\n            //      ####\n            //          ####\n            //            ####\n            //\n            // We handle overlap in the source and destination range by\n            // changing the copying direction. This prevents us from\n            // overwriting parts of source that we still need to copy.\n            //\n            // This correctly handles source == dest\n            //\n            if (source > dest) {\n                assembly {\n                    // We subtract 32 from `sEnd` and `dEnd` because it\n                    // is easier to compare with in the loop, and these\n                    // are also the addresses we need for copying the\n                    // last bytes.\n                    length := sub(length, 32)\n                    let sEnd := add(source, length)\n                    let dEnd := add(dest, length)\n\n                    // Remember the last 32 bytes of source\n                    // This needs to be done here and not after the loop\n                    // because we may have overwritten the last bytes in\n                    // source already due to overlap.\n                    let last := mload(sEnd)\n\n                    // Copy whole words front to back\n                    // Note: the first check is always true,\n                    // this could have been a do-while loop.\n                    // solhint-disable-next-line no-empty-blocks\n                    for {} lt(source, sEnd) {} {\n                        mstore(dest, mload(source))\n                        source := add(source, 32)\n                        dest := add(dest, 32)\n                    }\n\n                    // Write the last 32 bytes\n                    mstore(dEnd, last)\n                }\n            } else {\n                assembly {\n                    // We subtract 32 from `sEnd` and `dEnd` because those\n                    // are the starting points when copying a word at the end.\n                    length := sub(length, 32)\n                    let sEnd := add(source, length)\n                    let dEnd := add(dest, length)\n\n                    // Remember the first 32 bytes of source\n                    // This needs to be done here and not after the loop\n                    // because we may have overwritten the first bytes in\n                    // source already due to overlap.\n                    let first := mload(source)\n\n                    // Copy whole words back to front\n                    // We use a signed comparisson here to allow dEnd to become\n                    // negative (happens when source and dest < 32). Valid\n                    // addresses in local memory will never be larger than\n                    // 2**255, so they can be safely re-interpreted as signed.\n                    // Note: the first check is always true,\n                    // this could have been a do-while loop.\n                    // solhint-disable-next-line no-empty-blocks\n                    for {} slt(dest, dEnd) {} {\n                        mstore(dEnd, mload(sEnd))\n                        sEnd := sub(sEnd, 32)\n                        dEnd := sub(dEnd, 32)\n                    }\n\n                    // Write the first 32 bytes\n                    mstore(dest, first)\n                }\n            }\n        }\n    }\n\n    /// @dev Returns a slices from a byte array.\n    /// @param b The byte array to take a slice from.\n    /// @param from The starting index for the slice (inclusive).\n    /// @param to The final index for the slice (exclusive).\n    /// @return result The slice containing bytes at indices [from, to)\n    function slice(\n        bytes memory b,\n        uint256 from,\n        uint256 to\n    )\n        internal\n        pure\n        returns (bytes memory result)\n    {\n        // Ensure that the from and to positions are valid positions for a slice within\n        // the byte array that is being used.\n        if (from > to) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.FromLessThanOrEqualsToRequired,\n                from,\n                to\n            ));\n        }\n        if (to > b.length) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.ToLessThanOrEqualsLengthRequired,\n                to,\n                b.length\n            ));\n        }\n\n        // Create a new bytes structure and copy contents\n        result = new bytes(to - from);\n        memCopy(\n            result.contentAddress(),\n            b.contentAddress() + from,\n            result.length\n        );\n        return result;\n    }\n\n    /// @dev Returns a slice from a byte array without preserving the input.\n    /// @param b The byte array to take a slice from. Will be destroyed in the process.\n    /// @param from The starting index for the slice (inclusive).\n    /// @param to The final index for the slice (exclusive).\n    /// @return result The slice containing bytes at indices [from, to)\n    /// @dev When `from == 0`, the original array will match the slice. In other cases its state will be corrupted.\n    function sliceDestructive(\n        bytes memory b,\n        uint256 from,\n        uint256 to\n    )\n        internal\n        pure\n        returns (bytes memory result)\n    {\n        // Ensure that the from and to positions are valid positions for a slice within\n        // the byte array that is being used.\n        if (from > to) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.FromLessThanOrEqualsToRequired,\n                from,\n                to\n            ));\n        }\n        if (to > b.length) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.ToLessThanOrEqualsLengthRequired,\n                to,\n                b.length\n            ));\n        }\n\n        // Create a new bytes structure around [from, to) in-place.\n        assembly {\n            result := add(b, from)\n            mstore(result, sub(to, from))\n        }\n        return result;\n    }\n\n    /// @dev Pops the last byte off of a byte array by modifying its length.\n    /// @param b Byte array that will be modified.\n    /// @return The byte that was popped off.\n    function popLastByte(bytes memory b)\n        internal\n        pure\n        returns (bytes1 result)\n    {\n        if (b.length == 0) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanZeroRequired,\n                b.length,\n                0\n            ));\n        }\n\n        // Store last byte.\n        result = b[b.length - 1];\n\n        assembly {\n            // Decrement length of byte array.\n            let newLen := sub(mload(b), 1)\n            mstore(b, newLen)\n        }\n        return result;\n    }\n\n    /// @dev Tests equality of two byte arrays.\n    /// @param lhs First byte array to compare.\n    /// @param rhs Second byte array to compare.\n    /// @return True if arrays are the same. False otherwise.\n    function equals(\n        bytes memory lhs,\n        bytes memory rhs\n    )\n        internal\n        pure\n        returns (bool equal)\n    {\n        // Keccak gas cost is 30 + numWords * 6. This is a cheap way to compare.\n        // We early exit on unequal lengths, but keccak would also correctly\n        // handle this.\n        return lhs.length == rhs.length && keccak256(lhs) == keccak256(rhs);\n    }\n\n    /// @dev Reads an address from a position in a byte array.\n    /// @param b Byte array containing an address.\n    /// @param index Index in byte array of address.\n    /// @return address from byte array.\n    function readAddress(\n        bytes memory b,\n        uint256 index\n    )\n        internal\n        pure\n        returns (address result)\n    {\n        if (b.length < index + 20) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanOrEqualsTwentyRequired,\n                b.length,\n                index + 20 // 20 is length of address\n            ));\n        }\n\n        // Add offset to index:\n        // 1. Arrays are prefixed by 32-byte length parameter (add 32 to index)\n        // 2. Account for size difference between address length and 32-byte storage word (subtract 12 from index)\n        index += 20;\n\n        // Read address from array memory\n        assembly {\n            // 1. Add index to address of bytes array\n            // 2. Load 32-byte word from memory\n            // 3. Apply 20-byte mask to obtain address\n            result := and(mload(add(b, index)), 0xffffffffffffffffffffffffffffffffffffffff)\n        }\n        return result;\n    }\n\n    /// @dev Writes an address into a specific position in a byte array.\n    /// @param b Byte array to insert address into.\n    /// @param index Index in byte array of address.\n    /// @param input Address to put into byte array.\n    function writeAddress(\n        bytes memory b,\n        uint256 index,\n        address input\n    )\n        internal\n        pure\n    {\n        if (b.length < index + 20) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanOrEqualsTwentyRequired,\n                b.length,\n                index + 20 // 20 is length of address\n            ));\n        }\n\n        // Add offset to index:\n        // 1. Arrays are prefixed by 32-byte length parameter (add 32 to index)\n        // 2. Account for size difference between address length and 32-byte storage word (subtract 12 from index)\n        index += 20;\n\n        // Store address into array memory\n        assembly {\n            // The address occupies 20 bytes and mstore stores 32 bytes.\n            // First fetch the 32-byte word where we'll be storing the address, then\n            // apply a mask so we have only the bytes in the word that the address will not occupy.\n            // Then combine these bytes with the address and store the 32 bytes back to memory with mstore.\n\n            // 1. Add index to address of bytes array\n            // 2. Load 32-byte word from memory\n            // 3. Apply 12-byte mask to obtain extra bytes occupying word of memory where we'll store the address\n            let neighbors := and(\n                mload(add(b, index)),\n                0xffffffffffffffffffffffff0000000000000000000000000000000000000000\n            )\n\n            // Make sure input address is clean.\n            // (Solidity does not guarantee this)\n            input := and(input, 0xffffffffffffffffffffffffffffffffffffffff)\n\n            // Store the neighbors and address into memory\n            mstore(add(b, index), xor(input, neighbors))\n        }\n    }\n\n    /// @dev Reads a bytes32 value from a position in a byte array.\n    /// @param b Byte array containing a bytes32 value.\n    /// @param index Index in byte array of bytes32 value.\n    /// @return bytes32 value from byte array.\n    function readBytes32(\n        bytes memory b,\n        uint256 index\n    )\n        internal\n        pure\n        returns (bytes32 result)\n    {\n        if (b.length < index + 32) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanOrEqualsThirtyTwoRequired,\n                b.length,\n                index + 32\n            ));\n        }\n\n        // Arrays are prefixed by a 256 bit length parameter\n        index += 32;\n\n        // Read the bytes32 from array memory\n        assembly {\n            result := mload(add(b, index))\n        }\n        return result;\n    }\n\n    /// @dev Writes a bytes32 into a specific position in a byte array.\n    /// @param b Byte array to insert <input> into.\n    /// @param index Index in byte array of <input>.\n    /// @param input bytes32 to put into byte array.\n    function writeBytes32(\n        bytes memory b,\n        uint256 index,\n        bytes32 input\n    )\n        internal\n        pure\n    {\n        if (b.length < index + 32) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanOrEqualsThirtyTwoRequired,\n                b.length,\n                index + 32\n            ));\n        }\n\n        // Arrays are prefixed by a 256 bit length parameter\n        index += 32;\n\n        // Read the bytes32 from array memory\n        assembly {\n            mstore(add(b, index), input)\n        }\n    }\n\n    /// @dev Reads a uint256 value from a position in a byte array.\n    /// @param b Byte array containing a uint256 value.\n    /// @param index Index in byte array of uint256 value.\n    /// @return uint256 value from byte array.\n    function readUint256(\n        bytes memory b,\n        uint256 index\n    )\n        internal\n        pure\n        returns (uint256 result)\n    {\n        result = uint256(readBytes32(b, index));\n        return result;\n    }\n\n    /// @dev Writes a uint256 into a specific position in a byte array.\n    /// @param b Byte array to insert <input> into.\n    /// @param index Index in byte array of <input>.\n    /// @param input uint256 to put into byte array.\n    function writeUint256(\n        bytes memory b,\n        uint256 index,\n        uint256 input\n    )\n        internal\n        pure\n    {\n        writeBytes32(b, index, bytes32(input));\n    }\n\n    /// @dev Reads an unpadded bytes4 value from a position in a byte array.\n    /// @param b Byte array containing a bytes4 value.\n    /// @param index Index in byte array of bytes4 value.\n    /// @return bytes4 value from byte array.\n    function readBytes4(\n        bytes memory b,\n        uint256 index\n    )\n        internal\n        pure\n        returns (bytes4 result)\n    {\n        if (b.length < index + 4) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanOrEqualsFourRequired,\n                b.length,\n                index + 4\n            ));\n        }\n\n        // Arrays are prefixed by a 32 byte length field\n        index += 32;\n\n        // Read the bytes4 from array memory\n        assembly {\n            result := mload(add(b, index))\n            // Solidity does not require us to clean the trailing bytes.\n            // We do it anyway\n            result := and(result, 0xFFFFFFFF00000000000000000000000000000000000000000000000000000000)\n        }\n        return result;\n    }\n\n    /// @dev Writes a new length to a byte array.\n    ///      Decreasing length will lead to removing the corresponding lower order bytes from the byte array.\n    ///      Increasing length may lead to appending adjacent in-memory bytes to the end of the byte array.\n    /// @param b Bytes array to write new length to.\n    /// @param length New length of byte array.\n    function writeLength(bytes memory b, uint256 length)\n        internal\n        pure\n    {\n        assembly {\n            mstore(b, length)\n        }\n    }\n}\n"
        },
        "@0x/contracts-utils/contracts/src/LibBytesRichErrors.sol": {
            "id": 73,
            "content": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\nlibrary LibBytesRichErrors {\n\n    enum InvalidByteOperationErrorCodes {\n        FromLessThanOrEqualsToRequired,\n        ToLessThanOrEqualsLengthRequired,\n        LengthGreaterThanZeroRequired,\n        LengthGreaterThanOrEqualsFourRequired,\n        LengthGreaterThanOrEqualsTwentyRequired,\n        LengthGreaterThanOrEqualsThirtyTwoRequired,\n        LengthGreaterThanOrEqualsNestedBytesLengthRequired,\n        DestinationLengthGreaterThanOrEqualSourceLengthRequired\n    }\n\n    // bytes4(keccak256(\"InvalidByteOperationError(uint8,uint256,uint256)\"))\n    bytes4 internal constant INVALID_BYTE_OPERATION_ERROR_SELECTOR =\n        0x28006595;\n\n    // solhint-disable func-name-mixedcase\n    function InvalidByteOperationError(\n        InvalidByteOperationErrorCodes errorCode,\n        uint256 offset,\n        uint256 required\n    )\n        internal\n        pure\n        returns (bytes memory)\n    {\n        return abi.encodeWithSelector(\n            INVALID_BYTE_OPERATION_ERROR_SELECTOR,\n            errorCode,\n            offset,\n            required\n        );\n    }\n}\n"
        },
        "@0x/contracts-exchange-libs/contracts/src/IWallet.sol": {
            "id": 64,
            "content": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\npragma experimental ABIEncoderV2;\n\n\ncontract IWallet {\n\n    bytes4 internal constant LEGACY_WALLET_MAGIC_VALUE = 0xb0671381;\n\n    /// @dev Validates a hash with the `Wallet` signature type.\n    /// @param hash Message hash that is signed.\n    /// @param signature Proof of signing.\n    /// @return magicValue `bytes4(0xb0671381)` if the signature check succeeds.\n    function isValidSignature(\n        bytes32 hash,\n        bytes calldata signature\n    )\n        external\n        view\n        returns (bytes4 magicValue);\n}\n"
        },
        "@0x/contracts-utils/contracts/src/DeploymentConstants.sol": {
            "id": 68,
            "content": "/*\n\n  Copyright 2020 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\ncontract DeploymentConstants {\n\n    // solhint-disable separate-by-one-line-in-contract\n\n    // Mainnet addresses ///////////////////////////////////////////////////////\n    /// @dev Mainnet address of the WETH contract.\n    address constant private WETH_ADDRESS = 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2;\n    /// @dev Mainnet address of the KyberNetworkProxy contract.\n    address constant private KYBER_NETWORK_PROXY_ADDRESS = 0x9AAb3f75489902f3a48495025729a0AF77d4b11e;\n    /// @dev Mainnet address of the KyberHintHandler contract.\n    address constant private KYBER_HINT_HANDLER_ADDRESS = 0xa1C0Fa73c39CFBcC11ec9Eb1Afc665aba9996E2C;\n    /// @dev Mainnet address of the `UniswapExchangeFactory` contract.\n    address constant private UNISWAP_EXCHANGE_FACTORY_ADDRESS = 0xc0a47dFe034B400B47bDaD5FecDa2621de6c4d95;\n    /// @dev Mainnet address of the `UniswapV2Router01` contract.\n    address constant private UNISWAP_V2_ROUTER_01_ADDRESS = 0xf164fC0Ec4E93095b804a4795bBe1e041497b92a;\n    /// @dev Mainnet address of the Eth2Dai `MatchingMarket` contract.\n    address constant private ETH2DAI_ADDRESS = 0x794e6e91555438aFc3ccF1c5076A74F42133d08D;\n    /// @dev Mainnet address of the `ERC20BridgeProxy` contract\n    address constant private ERC20_BRIDGE_PROXY_ADDRESS = 0x8ED95d1746bf1E4dAb58d8ED4724f1Ef95B20Db0;\n    ///@dev Mainnet address of the `Dai` (multi-collateral) contract\n    address constant private DAI_ADDRESS = 0x6B175474E89094C44Da98b954EedeAC495271d0F;\n    /// @dev Mainnet address of the `Chai` contract\n    address constant private CHAI_ADDRESS = 0x06AF07097C9Eeb7fD685c692751D5C66dB49c215;\n    /// @dev Mainnet address of the 0x DevUtils contract.\n    address constant private DEV_UTILS_ADDRESS = 0x74134CF88b21383713E096a5ecF59e297dc7f547;\n    /// @dev Kyber ETH pseudo-address.\n    address constant internal KYBER_ETH_ADDRESS = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;\n    /// @dev Mainnet address of the dYdX contract.\n    address constant private DYDX_ADDRESS = 0x1E0447b19BB6EcFdAe1e4AE1694b0C3659614e4e;\n    /// @dev Mainnet address of the GST2 contract\n    address constant private GST_ADDRESS = 0x0000000000b3F879cb30FE243b4Dfee438691c04;\n    /// @dev Mainnet address of the GST Collector\n    address constant private GST_COLLECTOR_ADDRESS = 0x000000D3b08566BE75A6DB803C03C85C0c1c5B96;\n    /// @dev Mainnet address of the mStable mUSD contract.\n    address constant private MUSD_ADDRESS = 0xe2f2a5C287993345a840Db3B0845fbC70f5935a5;\n    /// @dev Mainnet address of the Mooniswap Registry contract\n    address constant private MOONISWAP_REGISTRY = 0x71CD6666064C3A1354a3B4dca5fA1E2D3ee7D303;\n    /// @dev Mainnet address of the DODO Registry (ZOO) contract\n    address constant private DODO_REGISTRY = 0x3A97247DF274a17C59A3bd12735ea3FcDFb49950;\n    /// @dev Mainnet address of the DODO Helper contract\n    address constant private DODO_HELPER = 0x533dA777aeDCE766CEAe696bf90f8541A4bA80Eb;\n\n    // // Ropsten addresses ///////////////////////////////////////////////////////\n    // /// @dev Mainnet address of the WETH contract.\n    // address constant private WETH_ADDRESS = 0xc778417E063141139Fce010982780140Aa0cD5Ab;\n    // /// @dev Mainnet address of the KyberNetworkProxy contract.\n    // address constant private KYBER_NETWORK_PROXY_ADDRESS = 0xd719c34261e099Fdb33030ac8909d5788D3039C4;\n    // /// @dev Mainnet address of the `UniswapExchangeFactory` contract.\n    // address constant private UNISWAP_EXCHANGE_FACTORY_ADDRESS = 0x9c83dCE8CA20E9aAF9D3efc003b2ea62aBC08351;\n    // /// @dev Mainnet address of the `UniswapV2Router01` contract.\n    // address constant private UNISWAP_V2_ROUTER_01_ADDRESS = 0xf164fC0Ec4E93095b804a4795bBe1e041497b92a;\n    // /// @dev Mainnet address of the Eth2Dai `MatchingMarket` contract.\n    // address constant private ETH2DAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the `ERC20BridgeProxy` contract\n    // address constant private ERC20_BRIDGE_PROXY_ADDRESS = 0xb344afeD348de15eb4a9e180205A2B0739628339;\n    // ///@dev Mainnet address of the `Dai` (multi-collateral) contract\n    // address constant private DAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the `Chai` contract\n    // address constant private CHAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the 0x DevUtils contract.\n    // address constant private DEV_UTILS_ADDRESS = 0xC812AF3f3fBC62F76ea4262576EC0f49dB8B7f1c;\n    // /// @dev Kyber ETH pseudo-address.\n    // address constant internal KYBER_ETH_ADDRESS = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;\n    // /// @dev Mainnet address of the dYdX contract.\n    // address constant private DYDX_ADDRESS = address(0);\n    // /// @dev Mainnet address of the GST2 contract\n    // address constant private GST_ADDRESS = address(0);\n    // /// @dev Mainnet address of the GST Collector\n    // address constant private GST_COLLECTOR_ADDRESS = address(0);\n    // /// @dev Mainnet address of the mStable mUSD contract.\n    // address constant private MUSD_ADDRESS = 0x4E1000616990D83e56f4b5fC6CC8602DcfD20459;\n\n    // // Rinkeby addresses ///////////////////////////////////////////////////////\n    // /// @dev Mainnet address of the WETH contract.\n    // address constant private WETH_ADDRESS = 0xc778417E063141139Fce010982780140Aa0cD5Ab;\n    // /// @dev Mainnet address of the KyberNetworkProxy contract.\n    // address constant private KYBER_NETWORK_PROXY_ADDRESS = 0x0d5371e5EE23dec7DF251A8957279629aa79E9C5;\n    // /// @dev Mainnet address of the `UniswapExchangeFactory` contract.\n    // address constant private UNISWAP_EXCHANGE_FACTORY_ADDRESS = 0xf5D915570BC477f9B8D6C0E980aA81757A3AaC36;\n    // /// @dev Mainnet address of the `UniswapV2Router01` contract.\n    // address constant private UNISWAP_V2_ROUTER_01_ADDRESS = 0xf164fC0Ec4E93095b804a4795bBe1e041497b92a;\n    // /// @dev Mainnet address of the Eth2Dai `MatchingMarket` contract.\n    // address constant private ETH2DAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the `ERC20BridgeProxy` contract\n    // address constant private ERC20_BRIDGE_PROXY_ADDRESS = 0xA2AA4bEFED748Fba27a3bE7Dfd2C4b2c6DB1F49B;\n    // ///@dev Mainnet address of the `Dai` (multi-collateral) contract\n    // address constant private DAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the `Chai` contract\n    // address constant private CHAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the 0x DevUtils contract.\n    // address constant private DEV_UTILS_ADDRESS = 0x46B5BC959e8A754c0256FFF73bF34A52Ad5CdfA9;\n    // /// @dev Kyber ETH pseudo-address.\n    // address constant internal KYBER_ETH_ADDRESS = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;\n    // /// @dev Mainnet address of the dYdX contract.\n    // address constant private DYDX_ADDRESS = address(0);\n    // /// @dev Mainnet address of the GST2 contract\n    // address constant private GST_ADDRESS = address(0);\n    // /// @dev Mainnet address of the GST Collector\n    // address constant private GST_COLLECTOR_ADDRESS = address(0);\n    // /// @dev Mainnet address of the mStable mUSD contract.\n    // address constant private MUSD_ADDRESS = address(0);\n\n    // // Kovan addresses /////////////////////////////////////////////////////////\n    // /// @dev Kovan address of the WETH contract.\n    // address constant private WETH_ADDRESS = 0xd0A1E359811322d97991E03f863a0C30C2cF029C;\n    // /// @dev Kovan address of the KyberNetworkProxy contract.\n    // address constant private KYBER_NETWORK_PROXY_ADDRESS = 0x692f391bCc85cefCe8C237C01e1f636BbD70EA4D;\n    // /// @dev Kovan address of the `UniswapExchangeFactory` contract.\n    // address constant private UNISWAP_EXCHANGE_FACTORY_ADDRESS = 0xD3E51Ef092B2845f10401a0159B2B96e8B6c3D30;\n    // /// @dev Kovan address of the `UniswapV2Router01` contract.\n    // address constant private UNISWAP_V2_ROUTER_01_ADDRESS = 0xf164fC0Ec4E93095b804a4795bBe1e041497b92a;\n    // /// @dev Kovan address of the Eth2Dai `MatchingMarket` contract.\n    // address constant private ETH2DAI_ADDRESS = 0xe325acB9765b02b8b418199bf9650972299235F4;\n    // /// @dev Kovan address of the `ERC20BridgeProxy` contract\n    // address constant private ERC20_BRIDGE_PROXY_ADDRESS = 0x3577552C1Fb7A44aD76BeEB7aB53251668A21F8D;\n    // /// @dev Kovan address of the `Chai` contract\n    // address constant private CHAI_ADDRESS = address(0);\n    // /// @dev Kovan address of the `Dai` (multi-collateral) contract\n    // address constant private DAI_ADDRESS = 0x4F96Fe3b7A6Cf9725f59d353F723c1bDb64CA6Aa;\n    // /// @dev Kovan address of the 0x DevUtils contract.\n    // address constant private DEV_UTILS_ADDRESS = 0x9402639A828BdF4E9e4103ac3B69E1a6E522eB59;\n    // /// @dev Kyber ETH pseudo-address.\n    // address constant internal KYBER_ETH_ADDRESS = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;\n    // /// @dev Kovan address of the dYdX contract.\n    // address constant private DYDX_ADDRESS = address(0);\n    // /// @dev Kovan address of the GST2 contract\n    // address constant private GST_ADDRESS = address(0);\n    // /// @dev Kovan address of the GST Collector\n    // address constant private GST_COLLECTOR_ADDRESS = address(0);\n    // /// @dev Mainnet address of the mStable mUSD contract.\n    // address constant private MUSD_ADDRESS = address(0);\n\n    /// @dev Overridable way to get the `KyberNetworkProxy` address.\n    /// @return kyberAddress The `IKyberNetworkProxy` address.\n    function _getKyberNetworkProxyAddress()\n        internal\n        view\n        returns (address kyberAddress)\n    {\n        return KYBER_NETWORK_PROXY_ADDRESS;\n    }\n\n    /// @dev Overridable way to get the `KyberHintHandler` address.\n    /// @return kyberAddress The `IKyberHintHandler` address.\n    function _getKyberHintHandlerAddress()\n        internal\n        view\n        returns (address hintHandlerAddress)\n    {\n        return KYBER_HINT_HANDLER_ADDRESS;\n    }\n\n    /// @dev Overridable way to get the WETH address.\n    /// @return wethAddress The WETH address.\n    function _getWethAddress()\n        internal\n        view\n        returns (address wethAddress)\n    {\n        return WETH_ADDRESS;\n    }\n\n    /// @dev Overridable way to get the `UniswapExchangeFactory` address.\n    /// @return uniswapAddress The `UniswapExchangeFactory` address.\n    function _getUniswapExchangeFactoryAddress()\n        internal\n        view\n        returns (address uniswapAddress)\n    {\n        return UNISWAP_EXCHANGE_FACTORY_ADDRESS;\n    }\n\n    /// @dev Overridable way to get the `UniswapV2Router01` address.\n    /// @return uniswapRouterAddress The `UniswapV2Router01` address.\n    function _getUniswapV2Router01Address()\n        internal\n        view\n        returns (address uniswapRouterAddress)\n    {\n        return UNISWAP_V2_ROUTER_01_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the Eth2Dai `MatchingMarket` contract.\n    /// @return eth2daiAddress The Eth2Dai `MatchingMarket` contract.\n    function _getEth2DaiAddress()\n        internal\n        view\n        returns (address eth2daiAddress)\n    {\n        return ETH2DAI_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the `ERC20BridgeProxy` contract.\n    /// @return erc20BridgeProxyAddress The `ERC20BridgeProxy` contract.\n    function _getERC20BridgeProxyAddress()\n        internal\n        view\n        returns (address erc20BridgeProxyAddress)\n    {\n        return ERC20_BRIDGE_PROXY_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the `Dai` contract.\n    /// @return daiAddress The `Dai` contract.\n    function _getDaiAddress()\n        internal\n        view\n        returns (address daiAddress)\n    {\n        return DAI_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the `Chai` contract.\n    /// @return chaiAddress The `Chai` contract.\n    function _getChaiAddress()\n        internal\n        view\n        returns (address chaiAddress)\n    {\n        return CHAI_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the 0x `DevUtils` contract address.\n    /// @return devUtils The 0x `DevUtils` contract address.\n    function _getDevUtilsAddress()\n        internal\n        view\n        returns (address devUtils)\n    {\n        return DEV_UTILS_ADDRESS;\n    }\n\n    /// @dev Overridable way to get the DyDx contract.\n    /// @return exchange The DyDx exchange contract.\n    function _getDydxAddress()\n        internal\n        view\n        returns (address dydxAddress)\n    {\n        return DYDX_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the GST2 contract address.\n    /// @return gst The GST contract.\n    function _getGstAddress()\n        internal\n        view\n        returns (address gst)\n    {\n        return GST_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the GST Collector address.\n    /// @return collector The GST collector address.\n    function _getGstCollectorAddress()\n        internal\n        view\n        returns (address collector)\n    {\n        return GST_COLLECTOR_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the mStable mUSD address.\n    /// @return musd The mStable mUSD address.\n    function _getMUsdAddress()\n        internal\n        view\n        returns (address musd)\n    {\n        return MUSD_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the Mooniswap registry address.\n    /// @return registry The Mooniswap registry address.\n    function _getMooniswapAddress()\n        internal\n        view\n        returns (address)\n    {\n        return MOONISWAP_REGISTRY;\n    }\n\n    /// @dev An overridable way to retrieve the DODO Registry contract address.\n    /// @return registry The DODO Registry contract address.\n    function _getDODORegistryAddress()\n        internal\n        view\n        returns (address)\n    {\n        return DODO_REGISTRY;\n    }\n\n    /// @dev An overridable way to retrieve the DODO Helper contract address.\n    /// @return registry The DODO Helper contract address.\n    function _getDODOHelperAddress()\n        internal\n        view\n        returns (address)\n    {\n        return DODO_HELPER;\n    }\n}\n"
        },
        "../interfaces/IUniswapExchangeFactory.sol": {
            "id": 47,
            "content": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\nimport \"./IUniswapExchange.sol\";\n\n\ninterface IUniswapExchangeFactory {\n\n    /// @dev Get the exchange for a token.\n    /// @param tokenAddress The address of the token contract.\n    function getExchange(address tokenAddress)\n        external\n        view\n        returns (address);\n}\n"
        },
        "../interfaces/IUniswapExchange.sol": {
            "id": 46,
            "content": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\ninterface IUniswapExchange {\n\n    /// @dev Buys at least `minTokensBought` tokens with ETH and transfer them\n    ///      to `recipient`.\n    /// @param minTokensBought The minimum number of tokens to buy.\n    /// @param deadline Time when this order expires.\n    /// @param recipient Who to transfer the tokens to.\n    /// @return tokensBought Amount of tokens bought.\n    function ethToTokenTransferInput(\n        uint256 minTokensBought,\n        uint256 deadline,\n        address recipient\n    )\n        external\n        payable\n        returns (uint256 tokensBought);\n\n    /// @dev Buys at least `minEthBought` ETH with tokens.\n    /// @param tokensSold Amount of tokens to sell.\n    /// @param minEthBought The minimum amount of ETH to buy.\n    /// @param deadline Time when this order expires.\n    /// @return ethBought Amount of tokens bought.\n    function tokenToEthSwapInput(\n        uint256 tokensSold,\n        uint256 minEthBought,\n        uint256 deadline\n    )\n        external\n        returns (uint256 ethBought);\n\n    /// @dev Buys at least `minTokensBought` tokens with the exchange token\n    ///      and transfer them to `recipient`.\n    /// @param minTokensBought The minimum number of tokens to buy.\n    /// @param minEthBought The minimum amount of intermediate ETH to buy.\n    /// @param deadline Time when this order expires.\n    /// @param recipient Who to transfer the tokens to.\n    /// @param toTokenAddress The token being bought.\n    /// @return tokensBought Amount of tokens bought.\n    function tokenToTokenTransferInput(\n        uint256 tokensSold,\n        uint256 minTokensBought,\n        uint256 minEthBought,\n        uint256 deadline,\n        address recipient,\n        address toTokenAddress\n    )\n        external\n        returns (uint256 tokensBought);\n}\n"
        },
        "../interfaces/IERC20Bridge.sol": {
            "id": 39,
            "content": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\ncontract IERC20Bridge {\n\n    /// @dev Result of a successful bridge call.\n    bytes4 constant internal BRIDGE_SUCCESS = 0xdc1600f3;\n\n    /// @dev Emitted when a trade occurs.\n    /// @param inputToken The token the bridge is converting from.\n    /// @param outputToken The token the bridge is converting to.\n    /// @param inputTokenAmount Amount of input token.\n    /// @param outputTokenAmount Amount of output token.\n    /// @param from The `from` address in `bridgeTransferFrom()`\n    /// @param to The `to` address in `bridgeTransferFrom()`\n    event ERC20BridgeTransfer(\n        address inputToken,\n        address outputToken,\n        uint256 inputTokenAmount,\n        uint256 outputTokenAmount,\n        address from,\n        address to\n    );\n\n    /// @dev Transfers `amount` of the ERC20 `tokenAddress` from `from` to `to`.\n    /// @param tokenAddress The address of the ERC20 token to transfer.\n    /// @param from Address to transfer asset from.\n    /// @param to Address to transfer asset to.\n    /// @param amount Amount of asset to transfer.\n    /// @param bridgeData Arbitrary asset data needed by the bridge contract.\n    /// @return success The magic bytes `0xdc1600f3` if successful.\n    function bridgeTransferFrom(\n        address tokenAddress,\n        address from,\n        address to,\n        uint256 amount,\n        bytes calldata bridgeData\n    )\n        external\n        returns (bytes4 success);\n}\n"
        }
    },
    "sourceCodes": {
        "./UniswapBridge.sol": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\npragma experimental ABIEncoderV2;\n\nimport \"@0x/contracts-erc20/contracts/src/interfaces/IERC20Token.sol\";\nimport \"@0x/contracts-erc20/contracts/src/interfaces/IEtherToken.sol\";\nimport \"@0x/contracts-erc20/contracts/src/LibERC20Token.sol\";\nimport \"@0x/contracts-exchange-libs/contracts/src/IWallet.sol\";\nimport \"@0x/contracts-utils/contracts/src/DeploymentConstants.sol\";\nimport \"../interfaces/IUniswapExchangeFactory.sol\";\nimport \"../interfaces/IUniswapExchange.sol\";\nimport \"../interfaces/IERC20Bridge.sol\";\n\n\n// solhint-disable space-after-comma\n// solhint-disable not-rely-on-time\ncontract UniswapBridge is\n    IERC20Bridge,\n    IWallet,\n    DeploymentConstants\n{\n    // Struct to hold `bridgeTransferFrom()` local variables in memory and to avoid\n    // stack overflows.\n    struct TransferState {\n        IUniswapExchange exchange;\n        uint256 fromTokenBalance;\n        IEtherToken weth;\n        uint256 boughtAmount;\n    }\n\n    // solhint-disable no-empty-blocks\n    /// @dev Payable fallback to receive ETH from uniswap.\n    function ()\n        external\n        payable\n    {}\n\n    /// @dev Callback for `IERC20Bridge`. Tries to buy `amount` of\n    ///      `toTokenAddress` tokens by selling the entirety of the `fromTokenAddress`\n    ///      token encoded in the bridge data.\n    /// @param toTokenAddress The token to buy and transfer to `to`.\n    /// @param from The maker (this contract).\n    /// @param to The recipient of the bought tokens.\n    /// @param amount Minimum amount of `toTokenAddress` tokens to buy.\n    /// @param bridgeData The abi-encoded \"from\" token address.\n    /// @return success The magic bytes if successful.\n    function bridgeTransferFrom(\n        address toTokenAddress,\n        address from,\n        address to,\n        uint256 amount,\n        bytes calldata bridgeData\n    )\n        external\n        returns (bytes4 success)\n    {\n        // State memory object to avoid stack overflows.\n        TransferState memory state;\n        // Decode the bridge data to get the `fromTokenAddress`.\n        (address fromTokenAddress) = abi.decode(bridgeData, (address));\n\n        // Just transfer the tokens if they're the same.\n        if (fromTokenAddress == toTokenAddress) {\n            LibERC20Token.transfer(fromTokenAddress, to, amount);\n            return BRIDGE_SUCCESS;\n        }\n\n        // Get the exchange for the token pair.\n        state.exchange = _getUniswapExchangeForTokenPair(\n            fromTokenAddress,\n            toTokenAddress\n        );\n        // Get our balance of `fromTokenAddress` token.\n        state.fromTokenBalance = IERC20Token(fromTokenAddress).balanceOf(address(this));\n        // Get the weth contract.\n        state.weth = IEtherToken(_getWethAddress());\n\n        // Convert from WETH to a token.\n        if (fromTokenAddress == address(state.weth)) {\n            // Unwrap the WETH.\n            state.weth.withdraw(state.fromTokenBalance);\n            // Buy as much of `toTokenAddress` token with ETH as possible and\n            // transfer it to `to`.\n            state.boughtAmount = state.exchange.ethToTokenTransferInput.value(state.fromTokenBalance)(\n                // Minimum buy amount.\n                amount,\n                // Expires after this block.\n                block.timestamp,\n                // Recipient is `to`.\n                to\n            );\n\n        // Convert from a token to WETH.\n        } else if (toTokenAddress == address(state.weth)) {\n            // Grant the exchange an allowance.\n            _grantExchangeAllowance(state.exchange, fromTokenAddress, state.fromTokenBalance);\n            // Buy as much ETH with `fromTokenAddress` token as possible.\n            state.boughtAmount = state.exchange.tokenToEthSwapInput(\n                // Sell all tokens we hold.\n                state.fromTokenBalance,\n                // Minimum buy amount.\n                amount,\n                // Expires after this block.\n                block.timestamp\n            );\n            // Wrap the ETH.\n            state.weth.deposit.value(state.boughtAmount)();\n            // Transfer the WETH to `to`.\n            IEtherToken(toTokenAddress).transfer(to, state.boughtAmount);\n\n        // Convert from one token to another.\n        } else {\n            // Grant the exchange an allowance.\n            _grantExchangeAllowance(state.exchange, fromTokenAddress, state.fromTokenBalance);\n            // Buy as much `toTokenAddress` token with `fromTokenAddress` token\n            // and transfer it to `to`.\n            state.boughtAmount = state.exchange.tokenToTokenTransferInput(\n                // Sell all tokens we hold.\n                state.fromTokenBalance,\n                // Minimum buy amount.\n                amount,\n                // Must buy at least 1 intermediate ETH.\n                1,\n                // Expires after this block.\n                block.timestamp,\n                // Recipient is `to`.\n                to,\n                // Convert to `toTokenAddress`.\n                toTokenAddress\n            );\n        }\n\n        emit ERC20BridgeTransfer(\n            fromTokenAddress,\n            toTokenAddress,\n            state.fromTokenBalance,\n            state.boughtAmount,\n            from,\n            to\n        );\n        return BRIDGE_SUCCESS;\n    }\n\n    /// @dev `SignatureType.Wallet` callback, so that this bridge can be the maker\n    ///      and sign for itself in orders. Always succeeds.\n    /// @return magicValue Success bytes, always.\n    function isValidSignature(\n        bytes32,\n        bytes calldata\n    )\n        external\n        view\n        returns (bytes4 magicValue)\n    {\n        return LEGACY_WALLET_MAGIC_VALUE;\n    }\n\n    /// @dev Grants an unlimited allowance to the exchange for its token\n    ///      on behalf of this contract.\n    /// @param exchange The Uniswap token exchange.\n    /// @param tokenAddress The token address for the exchange.\n    /// @param minimumAllowance The minimum necessary allowance.\n    function _grantExchangeAllowance(\n        IUniswapExchange exchange,\n        address tokenAddress,\n        uint256 minimumAllowance\n    )\n        private\n    {\n        LibERC20Token.approveIfBelow(\n            tokenAddress,\n            address(exchange),\n            minimumAllowance\n        );\n    }\n\n    /// @dev Retrieves the uniswap exchange for a given token pair.\n    ///      In the case of a WETH-token exchange, this will be the non-WETH token.\n    ///      In th ecase of a token-token exchange, this will be the first token.\n    /// @param fromTokenAddress The address of the token we are converting from.\n    /// @param toTokenAddress The address of the token we are converting to.\n    /// @return exchange The uniswap exchange.\n    function _getUniswapExchangeForTokenPair(\n        address fromTokenAddress,\n        address toTokenAddress\n    )\n        private\n        view\n        returns (IUniswapExchange exchange)\n    {\n        address exchangeTokenAddress = fromTokenAddress;\n        // Whichever isn't WETH is the exchange token.\n        if (fromTokenAddress == _getWethAddress()) {\n            exchangeTokenAddress = toTokenAddress;\n        }\n        exchange = IUniswapExchange(\n            IUniswapExchangeFactory(_getUniswapExchangeFactoryAddress())\n            .getExchange(exchangeTokenAddress)\n        );\n        require(address(exchange) != address(0), \"NO_UNISWAP_EXCHANGE_FOR_TOKEN\");\n        return exchange;\n    }\n}\n",
        "@0x/contracts-erc20/contracts/src/interfaces/IERC20Token.sol": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\ncontract IERC20Token {\n\n    // solhint-disable no-simple-event-func-name\n    event Transfer(\n        address indexed _from,\n        address indexed _to,\n        uint256 _value\n    );\n\n    event Approval(\n        address indexed _owner,\n        address indexed _spender,\n        uint256 _value\n    );\n\n    /// @dev send `value` token to `to` from `msg.sender`\n    /// @param _to The address of the recipient\n    /// @param _value The amount of token to be transferred\n    /// @return True if transfer was successful\n    function transfer(address _to, uint256 _value)\n        external\n        returns (bool);\n\n    /// @dev send `value` token to `to` from `from` on the condition it is approved by `from`\n    /// @param _from The address of the sender\n    /// @param _to The address of the recipient\n    /// @param _value The amount of token to be transferred\n    /// @return True if transfer was successful\n    function transferFrom(\n        address _from,\n        address _to,\n        uint256 _value\n    )\n        external\n        returns (bool);\n\n    /// @dev `msg.sender` approves `_spender` to spend `_value` tokens\n    /// @param _spender The address of the account able to transfer the tokens\n    /// @param _value The amount of wei to be approved for transfer\n    /// @return Always true if the call has enough gas to complete execution\n    function approve(address _spender, uint256 _value)\n        external\n        returns (bool);\n\n    /// @dev Query total supply of token\n    /// @return Total supply of token\n    function totalSupply()\n        external\n        view\n        returns (uint256);\n\n    /// @param _owner The address from which the balance will be retrieved\n    /// @return Balance of owner\n    function balanceOf(address _owner)\n        external\n        view\n        returns (uint256);\n\n    /// @param _owner The address of the account owning tokens\n    /// @param _spender The address of the account able to transfer the tokens\n    /// @return Amount of remaining tokens allowed to spent\n    function allowance(address _owner, address _spender)\n        external\n        view\n        returns (uint256);\n}\n",
        "@0x/contracts-erc20/contracts/src/interfaces/IEtherToken.sol": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\nimport \"./IERC20Token.sol\";\n\n\ncontract IEtherToken is\n    IERC20Token\n{\n    function deposit()\n        public\n        payable;\n    \n    function withdraw(uint256 amount)\n        public;\n}\n",
        "@0x/contracts-erc20/contracts/src/LibERC20Token.sol": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\nimport \"@0x/contracts-utils/contracts/src/LibRichErrors.sol\";\nimport \"@0x/contracts-utils/contracts/src/LibBytes.sol\";\nimport \"../src/interfaces/IERC20Token.sol\";\n\n\nlibrary LibERC20Token {\n    bytes constant private DECIMALS_CALL_DATA = hex\"313ce567\";\n\n    /// @dev Calls `IERC20Token(token).approve()`.\n    ///      Reverts if `false` is returned or if the return\n    ///      data length is nonzero and not 32 bytes.\n    /// @param token The address of the token contract.\n    /// @param spender The address that receives an allowance.\n    /// @param allowance The allowance to set.\n    function approve(\n        address token,\n        address spender,\n        uint256 allowance\n    )\n        internal\n    {\n        bytes memory callData = abi.encodeWithSelector(\n            IERC20Token(0).approve.selector,\n            spender,\n            allowance\n        );\n        _callWithOptionalBooleanResult(token, callData);\n    }\n\n    /// @dev Calls `IERC20Token(token).approve()` and sets the allowance to the\n    ///      maximum if the current approval is not already >= an amount.\n    ///      Reverts if `false` is returned or if the return\n    ///      data length is nonzero and not 32 bytes.\n    /// @param token The address of the token contract.\n    /// @param spender The address that receives an allowance.\n    /// @param amount The minimum allowance needed.\n    function approveIfBelow(\n        address token,\n        address spender,\n        uint256 amount\n    )\n        internal\n    {\n        if (IERC20Token(token).allowance(address(this), spender) < amount) {\n            approve(token, spender, uint256(-1));\n        }\n    }\n\n    /// @dev Calls `IERC20Token(token).transfer()`.\n    ///      Reverts if `false` is returned or if the return\n    ///      data length is nonzero and not 32 bytes.\n    /// @param token The address of the token contract.\n    /// @param to The address that receives the tokens\n    /// @param amount Number of tokens to transfer.\n    function transfer(\n        address token,\n        address to,\n        uint256 amount\n    )\n        internal\n    {\n        bytes memory callData = abi.encodeWithSelector(\n            IERC20Token(0).transfer.selector,\n            to,\n            amount\n        );\n        _callWithOptionalBooleanResult(token, callData);\n    }\n\n    /// @dev Calls `IERC20Token(token).transferFrom()`.\n    ///      Reverts if `false` is returned or if the return\n    ///      data length is nonzero and not 32 bytes.\n    /// @param token The address of the token contract.\n    /// @param from The owner of the tokens.\n    /// @param to The address that receives the tokens\n    /// @param amount Number of tokens to transfer.\n    function transferFrom(\n        address token,\n        address from,\n        address to,\n        uint256 amount\n    )\n        internal\n    {\n        bytes memory callData = abi.encodeWithSelector(\n            IERC20Token(0).transferFrom.selector,\n            from,\n            to,\n            amount\n        );\n        _callWithOptionalBooleanResult(token, callData);\n    }\n\n    /// @dev Retrieves the number of decimals for a token.\n    ///      Returns `18` if the call reverts.\n    /// @param token The address of the token contract.\n    /// @return tokenDecimals The number of decimals places for the token.\n    function decimals(address token)\n        internal\n        view\n        returns (uint8 tokenDecimals)\n    {\n        tokenDecimals = 18;\n        (bool didSucceed, bytes memory resultData) = token.staticcall(DECIMALS_CALL_DATA);\n        if (didSucceed && resultData.length == 32) {\n            tokenDecimals = uint8(LibBytes.readUint256(resultData, 0));\n        }\n    }\n\n    /// @dev Retrieves the allowance for a token, owner, and spender.\n    ///      Returns `0` if the call reverts.\n    /// @param token The address of the token contract.\n    /// @param owner The owner of the tokens.\n    /// @param spender The address the spender.\n    /// @return allowance The allowance for a token, owner, and spender.\n    function allowance(address token, address owner, address spender)\n        internal\n        view\n        returns (uint256 allowance_)\n    {\n        (bool didSucceed, bytes memory resultData) = token.staticcall(\n            abi.encodeWithSelector(\n                IERC20Token(0).allowance.selector,\n                owner,\n                spender\n            )\n        );\n        if (didSucceed && resultData.length == 32) {\n            allowance_ = LibBytes.readUint256(resultData, 0);\n        }\n    }\n\n    /// @dev Retrieves the balance for a token owner.\n    ///      Returns `0` if the call reverts.\n    /// @param token The address of the token contract.\n    /// @param owner The owner of the tokens.\n    /// @return balance The token balance of an owner.\n    function balanceOf(address token, address owner)\n        internal\n        view\n        returns (uint256 balance)\n    {\n        (bool didSucceed, bytes memory resultData) = token.staticcall(\n            abi.encodeWithSelector(\n                IERC20Token(0).balanceOf.selector,\n                owner\n            )\n        );\n        if (didSucceed && resultData.length == 32) {\n            balance = LibBytes.readUint256(resultData, 0);\n        }\n    }\n\n    /// @dev Executes a call on address `target` with calldata `callData`\n    ///      and asserts that either nothing was returned or a single boolean\n    ///      was returned equal to `true`.\n    /// @param target The call target.\n    /// @param callData The abi-encoded call data.\n    function _callWithOptionalBooleanResult(\n        address target,\n        bytes memory callData\n    )\n        private\n    {\n        (bool didSucceed, bytes memory resultData) = target.call(callData);\n        if (didSucceed) {\n            if (resultData.length == 0) {\n                return;\n            }\n            if (resultData.length == 32) {\n                uint256 result = LibBytes.readUint256(resultData, 0);\n                if (result == 1) {\n                    return;\n                }\n            }\n        }\n        LibRichErrors.rrevert(resultData);\n    }\n}\n",
        "@0x/contracts-utils/contracts/src/LibRichErrors.sol": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\nlibrary LibRichErrors {\n\n    // bytes4(keccak256(\"Error(string)\"))\n    bytes4 internal constant STANDARD_ERROR_SELECTOR =\n        0x08c379a0;\n\n    // solhint-disable func-name-mixedcase\n    /// @dev ABI encode a standard, string revert error payload.\n    ///      This is the same payload that would be included by a `revert(string)`\n    ///      solidity statement. It has the function signature `Error(string)`.\n    /// @param message The error string.\n    /// @return The ABI encoded error.\n    function StandardError(\n        string memory message\n    )\n        internal\n        pure\n        returns (bytes memory)\n    {\n        return abi.encodeWithSelector(\n            STANDARD_ERROR_SELECTOR,\n            bytes(message)\n        );\n    }\n    // solhint-enable func-name-mixedcase\n\n    /// @dev Reverts an encoded rich revert reason `errorData`.\n    /// @param errorData ABI encoded error data.\n    function rrevert(bytes memory errorData)\n        internal\n        pure\n    {\n        assembly {\n            revert(add(errorData, 0x20), mload(errorData))\n        }\n    }\n}\n",
        "@0x/contracts-utils/contracts/src/LibBytes.sol": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\nimport \"./LibBytesRichErrors.sol\";\nimport \"./LibRichErrors.sol\";\n\n\nlibrary LibBytes {\n\n    using LibBytes for bytes;\n\n    /// @dev Gets the memory address for a byte array.\n    /// @param input Byte array to lookup.\n    /// @return memoryAddress Memory address of byte array. This\n    ///         points to the header of the byte array which contains\n    ///         the length.\n    function rawAddress(bytes memory input)\n        internal\n        pure\n        returns (uint256 memoryAddress)\n    {\n        assembly {\n            memoryAddress := input\n        }\n        return memoryAddress;\n    }\n\n    /// @dev Gets the memory address for the contents of a byte array.\n    /// @param input Byte array to lookup.\n    /// @return memoryAddress Memory address of the contents of the byte array.\n    function contentAddress(bytes memory input)\n        internal\n        pure\n        returns (uint256 memoryAddress)\n    {\n        assembly {\n            memoryAddress := add(input, 32)\n        }\n        return memoryAddress;\n    }\n\n    /// @dev Copies `length` bytes from memory location `source` to `dest`.\n    /// @param dest memory address to copy bytes to.\n    /// @param source memory address to copy bytes from.\n    /// @param length number of bytes to copy.\n    function memCopy(\n        uint256 dest,\n        uint256 source,\n        uint256 length\n    )\n        internal\n        pure\n    {\n        if (length < 32) {\n            // Handle a partial word by reading destination and masking\n            // off the bits we are interested in.\n            // This correctly handles overlap, zero lengths and source == dest\n            assembly {\n                let mask := sub(exp(256, sub(32, length)), 1)\n                let s := and(mload(source), not(mask))\n                let d := and(mload(dest), mask)\n                mstore(dest, or(s, d))\n            }\n        } else {\n            // Skip the O(length) loop when source == dest.\n            if (source == dest) {\n                return;\n            }\n\n            // For large copies we copy whole words at a time. The final\n            // word is aligned to the end of the range (instead of after the\n            // previous) to handle partial words. So a copy will look like this:\n            //\n            //  ####\n            //      ####\n            //          ####\n            //            ####\n            //\n            // We handle overlap in the source and destination range by\n            // changing the copying direction. This prevents us from\n            // overwriting parts of source that we still need to copy.\n            //\n            // This correctly handles source == dest\n            //\n            if (source > dest) {\n                assembly {\n                    // We subtract 32 from `sEnd` and `dEnd` because it\n                    // is easier to compare with in the loop, and these\n                    // are also the addresses we need for copying the\n                    // last bytes.\n                    length := sub(length, 32)\n                    let sEnd := add(source, length)\n                    let dEnd := add(dest, length)\n\n                    // Remember the last 32 bytes of source\n                    // This needs to be done here and not after the loop\n                    // because we may have overwritten the last bytes in\n                    // source already due to overlap.\n                    let last := mload(sEnd)\n\n                    // Copy whole words front to back\n                    // Note: the first check is always true,\n                    // this could have been a do-while loop.\n                    // solhint-disable-next-line no-empty-blocks\n                    for {} lt(source, sEnd) {} {\n                        mstore(dest, mload(source))\n                        source := add(source, 32)\n                        dest := add(dest, 32)\n                    }\n\n                    // Write the last 32 bytes\n                    mstore(dEnd, last)\n                }\n            } else {\n                assembly {\n                    // We subtract 32 from `sEnd` and `dEnd` because those\n                    // are the starting points when copying a word at the end.\n                    length := sub(length, 32)\n                    let sEnd := add(source, length)\n                    let dEnd := add(dest, length)\n\n                    // Remember the first 32 bytes of source\n                    // This needs to be done here and not after the loop\n                    // because we may have overwritten the first bytes in\n                    // source already due to overlap.\n                    let first := mload(source)\n\n                    // Copy whole words back to front\n                    // We use a signed comparisson here to allow dEnd to become\n                    // negative (happens when source and dest < 32). Valid\n                    // addresses in local memory will never be larger than\n                    // 2**255, so they can be safely re-interpreted as signed.\n                    // Note: the first check is always true,\n                    // this could have been a do-while loop.\n                    // solhint-disable-next-line no-empty-blocks\n                    for {} slt(dest, dEnd) {} {\n                        mstore(dEnd, mload(sEnd))\n                        sEnd := sub(sEnd, 32)\n                        dEnd := sub(dEnd, 32)\n                    }\n\n                    // Write the first 32 bytes\n                    mstore(dest, first)\n                }\n            }\n        }\n    }\n\n    /// @dev Returns a slices from a byte array.\n    /// @param b The byte array to take a slice from.\n    /// @param from The starting index for the slice (inclusive).\n    /// @param to The final index for the slice (exclusive).\n    /// @return result The slice containing bytes at indices [from, to)\n    function slice(\n        bytes memory b,\n        uint256 from,\n        uint256 to\n    )\n        internal\n        pure\n        returns (bytes memory result)\n    {\n        // Ensure that the from and to positions are valid positions for a slice within\n        // the byte array that is being used.\n        if (from > to) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.FromLessThanOrEqualsToRequired,\n                from,\n                to\n            ));\n        }\n        if (to > b.length) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.ToLessThanOrEqualsLengthRequired,\n                to,\n                b.length\n            ));\n        }\n\n        // Create a new bytes structure and copy contents\n        result = new bytes(to - from);\n        memCopy(\n            result.contentAddress(),\n            b.contentAddress() + from,\n            result.length\n        );\n        return result;\n    }\n\n    /// @dev Returns a slice from a byte array without preserving the input.\n    /// @param b The byte array to take a slice from. Will be destroyed in the process.\n    /// @param from The starting index for the slice (inclusive).\n    /// @param to The final index for the slice (exclusive).\n    /// @return result The slice containing bytes at indices [from, to)\n    /// @dev When `from == 0`, the original array will match the slice. In other cases its state will be corrupted.\n    function sliceDestructive(\n        bytes memory b,\n        uint256 from,\n        uint256 to\n    )\n        internal\n        pure\n        returns (bytes memory result)\n    {\n        // Ensure that the from and to positions are valid positions for a slice within\n        // the byte array that is being used.\n        if (from > to) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.FromLessThanOrEqualsToRequired,\n                from,\n                to\n            ));\n        }\n        if (to > b.length) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.ToLessThanOrEqualsLengthRequired,\n                to,\n                b.length\n            ));\n        }\n\n        // Create a new bytes structure around [from, to) in-place.\n        assembly {\n            result := add(b, from)\n            mstore(result, sub(to, from))\n        }\n        return result;\n    }\n\n    /// @dev Pops the last byte off of a byte array by modifying its length.\n    /// @param b Byte array that will be modified.\n    /// @return The byte that was popped off.\n    function popLastByte(bytes memory b)\n        internal\n        pure\n        returns (bytes1 result)\n    {\n        if (b.length == 0) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanZeroRequired,\n                b.length,\n                0\n            ));\n        }\n\n        // Store last byte.\n        result = b[b.length - 1];\n\n        assembly {\n            // Decrement length of byte array.\n            let newLen := sub(mload(b), 1)\n            mstore(b, newLen)\n        }\n        return result;\n    }\n\n    /// @dev Tests equality of two byte arrays.\n    /// @param lhs First byte array to compare.\n    /// @param rhs Second byte array to compare.\n    /// @return True if arrays are the same. False otherwise.\n    function equals(\n        bytes memory lhs,\n        bytes memory rhs\n    )\n        internal\n        pure\n        returns (bool equal)\n    {\n        // Keccak gas cost is 30 + numWords * 6. This is a cheap way to compare.\n        // We early exit on unequal lengths, but keccak would also correctly\n        // handle this.\n        return lhs.length == rhs.length && keccak256(lhs) == keccak256(rhs);\n    }\n\n    /// @dev Reads an address from a position in a byte array.\n    /// @param b Byte array containing an address.\n    /// @param index Index in byte array of address.\n    /// @return address from byte array.\n    function readAddress(\n        bytes memory b,\n        uint256 index\n    )\n        internal\n        pure\n        returns (address result)\n    {\n        if (b.length < index + 20) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanOrEqualsTwentyRequired,\n                b.length,\n                index + 20 // 20 is length of address\n            ));\n        }\n\n        // Add offset to index:\n        // 1. Arrays are prefixed by 32-byte length parameter (add 32 to index)\n        // 2. Account for size difference between address length and 32-byte storage word (subtract 12 from index)\n        index += 20;\n\n        // Read address from array memory\n        assembly {\n            // 1. Add index to address of bytes array\n            // 2. Load 32-byte word from memory\n            // 3. Apply 20-byte mask to obtain address\n            result := and(mload(add(b, index)), 0xffffffffffffffffffffffffffffffffffffffff)\n        }\n        return result;\n    }\n\n    /// @dev Writes an address into a specific position in a byte array.\n    /// @param b Byte array to insert address into.\n    /// @param index Index in byte array of address.\n    /// @param input Address to put into byte array.\n    function writeAddress(\n        bytes memory b,\n        uint256 index,\n        address input\n    )\n        internal\n        pure\n    {\n        if (b.length < index + 20) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanOrEqualsTwentyRequired,\n                b.length,\n                index + 20 // 20 is length of address\n            ));\n        }\n\n        // Add offset to index:\n        // 1. Arrays are prefixed by 32-byte length parameter (add 32 to index)\n        // 2. Account for size difference between address length and 32-byte storage word (subtract 12 from index)\n        index += 20;\n\n        // Store address into array memory\n        assembly {\n            // The address occupies 20 bytes and mstore stores 32 bytes.\n            // First fetch the 32-byte word where we'll be storing the address, then\n            // apply a mask so we have only the bytes in the word that the address will not occupy.\n            // Then combine these bytes with the address and store the 32 bytes back to memory with mstore.\n\n            // 1. Add index to address of bytes array\n            // 2. Load 32-byte word from memory\n            // 3. Apply 12-byte mask to obtain extra bytes occupying word of memory where we'll store the address\n            let neighbors := and(\n                mload(add(b, index)),\n                0xffffffffffffffffffffffff0000000000000000000000000000000000000000\n            )\n\n            // Make sure input address is clean.\n            // (Solidity does not guarantee this)\n            input := and(input, 0xffffffffffffffffffffffffffffffffffffffff)\n\n            // Store the neighbors and address into memory\n            mstore(add(b, index), xor(input, neighbors))\n        }\n    }\n\n    /// @dev Reads a bytes32 value from a position in a byte array.\n    /// @param b Byte array containing a bytes32 value.\n    /// @param index Index in byte array of bytes32 value.\n    /// @return bytes32 value from byte array.\n    function readBytes32(\n        bytes memory b,\n        uint256 index\n    )\n        internal\n        pure\n        returns (bytes32 result)\n    {\n        if (b.length < index + 32) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanOrEqualsThirtyTwoRequired,\n                b.length,\n                index + 32\n            ));\n        }\n\n        // Arrays are prefixed by a 256 bit length parameter\n        index += 32;\n\n        // Read the bytes32 from array memory\n        assembly {\n            result := mload(add(b, index))\n        }\n        return result;\n    }\n\n    /// @dev Writes a bytes32 into a specific position in a byte array.\n    /// @param b Byte array to insert <input> into.\n    /// @param index Index in byte array of <input>.\n    /// @param input bytes32 to put into byte array.\n    function writeBytes32(\n        bytes memory b,\n        uint256 index,\n        bytes32 input\n    )\n        internal\n        pure\n    {\n        if (b.length < index + 32) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanOrEqualsThirtyTwoRequired,\n                b.length,\n                index + 32\n            ));\n        }\n\n        // Arrays are prefixed by a 256 bit length parameter\n        index += 32;\n\n        // Read the bytes32 from array memory\n        assembly {\n            mstore(add(b, index), input)\n        }\n    }\n\n    /// @dev Reads a uint256 value from a position in a byte array.\n    /// @param b Byte array containing a uint256 value.\n    /// @param index Index in byte array of uint256 value.\n    /// @return uint256 value from byte array.\n    function readUint256(\n        bytes memory b,\n        uint256 index\n    )\n        internal\n        pure\n        returns (uint256 result)\n    {\n        result = uint256(readBytes32(b, index));\n        return result;\n    }\n\n    /// @dev Writes a uint256 into a specific position in a byte array.\n    /// @param b Byte array to insert <input> into.\n    /// @param index Index in byte array of <input>.\n    /// @param input uint256 to put into byte array.\n    function writeUint256(\n        bytes memory b,\n        uint256 index,\n        uint256 input\n    )\n        internal\n        pure\n    {\n        writeBytes32(b, index, bytes32(input));\n    }\n\n    /// @dev Reads an unpadded bytes4 value from a position in a byte array.\n    /// @param b Byte array containing a bytes4 value.\n    /// @param index Index in byte array of bytes4 value.\n    /// @return bytes4 value from byte array.\n    function readBytes4(\n        bytes memory b,\n        uint256 index\n    )\n        internal\n        pure\n        returns (bytes4 result)\n    {\n        if (b.length < index + 4) {\n            LibRichErrors.rrevert(LibBytesRichErrors.InvalidByteOperationError(\n                LibBytesRichErrors.InvalidByteOperationErrorCodes.LengthGreaterThanOrEqualsFourRequired,\n                b.length,\n                index + 4\n            ));\n        }\n\n        // Arrays are prefixed by a 32 byte length field\n        index += 32;\n\n        // Read the bytes4 from array memory\n        assembly {\n            result := mload(add(b, index))\n            // Solidity does not require us to clean the trailing bytes.\n            // We do it anyway\n            result := and(result, 0xFFFFFFFF00000000000000000000000000000000000000000000000000000000)\n        }\n        return result;\n    }\n\n    /// @dev Writes a new length to a byte array.\n    ///      Decreasing length will lead to removing the corresponding lower order bytes from the byte array.\n    ///      Increasing length may lead to appending adjacent in-memory bytes to the end of the byte array.\n    /// @param b Bytes array to write new length to.\n    /// @param length New length of byte array.\n    function writeLength(bytes memory b, uint256 length)\n        internal\n        pure\n    {\n        assembly {\n            mstore(b, length)\n        }\n    }\n}\n",
        "@0x/contracts-utils/contracts/src/LibBytesRichErrors.sol": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\nlibrary LibBytesRichErrors {\n\n    enum InvalidByteOperationErrorCodes {\n        FromLessThanOrEqualsToRequired,\n        ToLessThanOrEqualsLengthRequired,\n        LengthGreaterThanZeroRequired,\n        LengthGreaterThanOrEqualsFourRequired,\n        LengthGreaterThanOrEqualsTwentyRequired,\n        LengthGreaterThanOrEqualsThirtyTwoRequired,\n        LengthGreaterThanOrEqualsNestedBytesLengthRequired,\n        DestinationLengthGreaterThanOrEqualSourceLengthRequired\n    }\n\n    // bytes4(keccak256(\"InvalidByteOperationError(uint8,uint256,uint256)\"))\n    bytes4 internal constant INVALID_BYTE_OPERATION_ERROR_SELECTOR =\n        0x28006595;\n\n    // solhint-disable func-name-mixedcase\n    function InvalidByteOperationError(\n        InvalidByteOperationErrorCodes errorCode,\n        uint256 offset,\n        uint256 required\n    )\n        internal\n        pure\n        returns (bytes memory)\n    {\n        return abi.encodeWithSelector(\n            INVALID_BYTE_OPERATION_ERROR_SELECTOR,\n            errorCode,\n            offset,\n            required\n        );\n    }\n}\n",
        "@0x/contracts-exchange-libs/contracts/src/IWallet.sol": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\npragma experimental ABIEncoderV2;\n\n\ncontract IWallet {\n\n    bytes4 internal constant LEGACY_WALLET_MAGIC_VALUE = 0xb0671381;\n\n    /// @dev Validates a hash with the `Wallet` signature type.\n    /// @param hash Message hash that is signed.\n    /// @param signature Proof of signing.\n    /// @return magicValue `bytes4(0xb0671381)` if the signature check succeeds.\n    function isValidSignature(\n        bytes32 hash,\n        bytes calldata signature\n    )\n        external\n        view\n        returns (bytes4 magicValue);\n}\n",
        "@0x/contracts-utils/contracts/src/DeploymentConstants.sol": "/*\n\n  Copyright 2020 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\ncontract DeploymentConstants {\n\n    // solhint-disable separate-by-one-line-in-contract\n\n    // Mainnet addresses ///////////////////////////////////////////////////////\n    /// @dev Mainnet address of the WETH contract.\n    address constant private WETH_ADDRESS = 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2;\n    /// @dev Mainnet address of the KyberNetworkProxy contract.\n    address constant private KYBER_NETWORK_PROXY_ADDRESS = 0x9AAb3f75489902f3a48495025729a0AF77d4b11e;\n    /// @dev Mainnet address of the KyberHintHandler contract.\n    address constant private KYBER_HINT_HANDLER_ADDRESS = 0xa1C0Fa73c39CFBcC11ec9Eb1Afc665aba9996E2C;\n    /// @dev Mainnet address of the `UniswapExchangeFactory` contract.\n    address constant private UNISWAP_EXCHANGE_FACTORY_ADDRESS = 0xc0a47dFe034B400B47bDaD5FecDa2621de6c4d95;\n    /// @dev Mainnet address of the `UniswapV2Router01` contract.\n    address constant private UNISWAP_V2_ROUTER_01_ADDRESS = 0xf164fC0Ec4E93095b804a4795bBe1e041497b92a;\n    /// @dev Mainnet address of the Eth2Dai `MatchingMarket` contract.\n    address constant private ETH2DAI_ADDRESS = 0x794e6e91555438aFc3ccF1c5076A74F42133d08D;\n    /// @dev Mainnet address of the `ERC20BridgeProxy` contract\n    address constant private ERC20_BRIDGE_PROXY_ADDRESS = 0x8ED95d1746bf1E4dAb58d8ED4724f1Ef95B20Db0;\n    ///@dev Mainnet address of the `Dai` (multi-collateral) contract\n    address constant private DAI_ADDRESS = 0x6B175474E89094C44Da98b954EedeAC495271d0F;\n    /// @dev Mainnet address of the `Chai` contract\n    address constant private CHAI_ADDRESS = 0x06AF07097C9Eeb7fD685c692751D5C66dB49c215;\n    /// @dev Mainnet address of the 0x DevUtils contract.\n    address constant private DEV_UTILS_ADDRESS = 0x74134CF88b21383713E096a5ecF59e297dc7f547;\n    /// @dev Kyber ETH pseudo-address.\n    address constant internal KYBER_ETH_ADDRESS = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;\n    /// @dev Mainnet address of the dYdX contract.\n    address constant private DYDX_ADDRESS = 0x1E0447b19BB6EcFdAe1e4AE1694b0C3659614e4e;\n    /// @dev Mainnet address of the GST2 contract\n    address constant private GST_ADDRESS = 0x0000000000b3F879cb30FE243b4Dfee438691c04;\n    /// @dev Mainnet address of the GST Collector\n    address constant private GST_COLLECTOR_ADDRESS = 0x000000D3b08566BE75A6DB803C03C85C0c1c5B96;\n    /// @dev Mainnet address of the mStable mUSD contract.\n    address constant private MUSD_ADDRESS = 0xe2f2a5C287993345a840Db3B0845fbC70f5935a5;\n    /// @dev Mainnet address of the Mooniswap Registry contract\n    address constant private MOONISWAP_REGISTRY = 0x71CD6666064C3A1354a3B4dca5fA1E2D3ee7D303;\n    /// @dev Mainnet address of the DODO Registry (ZOO) contract\n    address constant private DODO_REGISTRY = 0x3A97247DF274a17C59A3bd12735ea3FcDFb49950;\n    /// @dev Mainnet address of the DODO Helper contract\n    address constant private DODO_HELPER = 0x533dA777aeDCE766CEAe696bf90f8541A4bA80Eb;\n\n    // // Ropsten addresses ///////////////////////////////////////////////////////\n    // /// @dev Mainnet address of the WETH contract.\n    // address constant private WETH_ADDRESS = 0xc778417E063141139Fce010982780140Aa0cD5Ab;\n    // /// @dev Mainnet address of the KyberNetworkProxy contract.\n    // address constant private KYBER_NETWORK_PROXY_ADDRESS = 0xd719c34261e099Fdb33030ac8909d5788D3039C4;\n    // /// @dev Mainnet address of the `UniswapExchangeFactory` contract.\n    // address constant private UNISWAP_EXCHANGE_FACTORY_ADDRESS = 0x9c83dCE8CA20E9aAF9D3efc003b2ea62aBC08351;\n    // /// @dev Mainnet address of the `UniswapV2Router01` contract.\n    // address constant private UNISWAP_V2_ROUTER_01_ADDRESS = 0xf164fC0Ec4E93095b804a4795bBe1e041497b92a;\n    // /// @dev Mainnet address of the Eth2Dai `MatchingMarket` contract.\n    // address constant private ETH2DAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the `ERC20BridgeProxy` contract\n    // address constant private ERC20_BRIDGE_PROXY_ADDRESS = 0xb344afeD348de15eb4a9e180205A2B0739628339;\n    // ///@dev Mainnet address of the `Dai` (multi-collateral) contract\n    // address constant private DAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the `Chai` contract\n    // address constant private CHAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the 0x DevUtils contract.\n    // address constant private DEV_UTILS_ADDRESS = 0xC812AF3f3fBC62F76ea4262576EC0f49dB8B7f1c;\n    // /// @dev Kyber ETH pseudo-address.\n    // address constant internal KYBER_ETH_ADDRESS = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;\n    // /// @dev Mainnet address of the dYdX contract.\n    // address constant private DYDX_ADDRESS = address(0);\n    // /// @dev Mainnet address of the GST2 contract\n    // address constant private GST_ADDRESS = address(0);\n    // /// @dev Mainnet address of the GST Collector\n    // address constant private GST_COLLECTOR_ADDRESS = address(0);\n    // /// @dev Mainnet address of the mStable mUSD contract.\n    // address constant private MUSD_ADDRESS = 0x4E1000616990D83e56f4b5fC6CC8602DcfD20459;\n\n    // // Rinkeby addresses ///////////////////////////////////////////////////////\n    // /// @dev Mainnet address of the WETH contract.\n    // address constant private WETH_ADDRESS = 0xc778417E063141139Fce010982780140Aa0cD5Ab;\n    // /// @dev Mainnet address of the KyberNetworkProxy contract.\n    // address constant private KYBER_NETWORK_PROXY_ADDRESS = 0x0d5371e5EE23dec7DF251A8957279629aa79E9C5;\n    // /// @dev Mainnet address of the `UniswapExchangeFactory` contract.\n    // address constant private UNISWAP_EXCHANGE_FACTORY_ADDRESS = 0xf5D915570BC477f9B8D6C0E980aA81757A3AaC36;\n    // /// @dev Mainnet address of the `UniswapV2Router01` contract.\n    // address constant private UNISWAP_V2_ROUTER_01_ADDRESS = 0xf164fC0Ec4E93095b804a4795bBe1e041497b92a;\n    // /// @dev Mainnet address of the Eth2Dai `MatchingMarket` contract.\n    // address constant private ETH2DAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the `ERC20BridgeProxy` contract\n    // address constant private ERC20_BRIDGE_PROXY_ADDRESS = 0xA2AA4bEFED748Fba27a3bE7Dfd2C4b2c6DB1F49B;\n    // ///@dev Mainnet address of the `Dai` (multi-collateral) contract\n    // address constant private DAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the `Chai` contract\n    // address constant private CHAI_ADDRESS = address(0);\n    // /// @dev Mainnet address of the 0x DevUtils contract.\n    // address constant private DEV_UTILS_ADDRESS = 0x46B5BC959e8A754c0256FFF73bF34A52Ad5CdfA9;\n    // /// @dev Kyber ETH pseudo-address.\n    // address constant internal KYBER_ETH_ADDRESS = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;\n    // /// @dev Mainnet address of the dYdX contract.\n    // address constant private DYDX_ADDRESS = address(0);\n    // /// @dev Mainnet address of the GST2 contract\n    // address constant private GST_ADDRESS = address(0);\n    // /// @dev Mainnet address of the GST Collector\n    // address constant private GST_COLLECTOR_ADDRESS = address(0);\n    // /// @dev Mainnet address of the mStable mUSD contract.\n    // address constant private MUSD_ADDRESS = address(0);\n\n    // // Kovan addresses /////////////////////////////////////////////////////////\n    // /// @dev Kovan address of the WETH contract.\n    // address constant private WETH_ADDRESS = 0xd0A1E359811322d97991E03f863a0C30C2cF029C;\n    // /// @dev Kovan address of the KyberNetworkProxy contract.\n    // address constant private KYBER_NETWORK_PROXY_ADDRESS = 0x692f391bCc85cefCe8C237C01e1f636BbD70EA4D;\n    // /// @dev Kovan address of the `UniswapExchangeFactory` contract.\n    // address constant private UNISWAP_EXCHANGE_FACTORY_ADDRESS = 0xD3E51Ef092B2845f10401a0159B2B96e8B6c3D30;\n    // /// @dev Kovan address of the `UniswapV2Router01` contract.\n    // address constant private UNISWAP_V2_ROUTER_01_ADDRESS = 0xf164fC0Ec4E93095b804a4795bBe1e041497b92a;\n    // /// @dev Kovan address of the Eth2Dai `MatchingMarket` contract.\n    // address constant private ETH2DAI_ADDRESS = 0xe325acB9765b02b8b418199bf9650972299235F4;\n    // /// @dev Kovan address of the `ERC20BridgeProxy` contract\n    // address constant private ERC20_BRIDGE_PROXY_ADDRESS = 0x3577552C1Fb7A44aD76BeEB7aB53251668A21F8D;\n    // /// @dev Kovan address of the `Chai` contract\n    // address constant private CHAI_ADDRESS = address(0);\n    // /// @dev Kovan address of the `Dai` (multi-collateral) contract\n    // address constant private DAI_ADDRESS = 0x4F96Fe3b7A6Cf9725f59d353F723c1bDb64CA6Aa;\n    // /// @dev Kovan address of the 0x DevUtils contract.\n    // address constant private DEV_UTILS_ADDRESS = 0x9402639A828BdF4E9e4103ac3B69E1a6E522eB59;\n    // /// @dev Kyber ETH pseudo-address.\n    // address constant internal KYBER_ETH_ADDRESS = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;\n    // /// @dev Kovan address of the dYdX contract.\n    // address constant private DYDX_ADDRESS = address(0);\n    // /// @dev Kovan address of the GST2 contract\n    // address constant private GST_ADDRESS = address(0);\n    // /// @dev Kovan address of the GST Collector\n    // address constant private GST_COLLECTOR_ADDRESS = address(0);\n    // /// @dev Mainnet address of the mStable mUSD contract.\n    // address constant private MUSD_ADDRESS = address(0);\n\n    /// @dev Overridable way to get the `KyberNetworkProxy` address.\n    /// @return kyberAddress The `IKyberNetworkProxy` address.\n    function _getKyberNetworkProxyAddress()\n        internal\n        view\n        returns (address kyberAddress)\n    {\n        return KYBER_NETWORK_PROXY_ADDRESS;\n    }\n\n    /// @dev Overridable way to get the `KyberHintHandler` address.\n    /// @return kyberAddress The `IKyberHintHandler` address.\n    function _getKyberHintHandlerAddress()\n        internal\n        view\n        returns (address hintHandlerAddress)\n    {\n        return KYBER_HINT_HANDLER_ADDRESS;\n    }\n\n    /// @dev Overridable way to get the WETH address.\n    /// @return wethAddress The WETH address.\n    function _getWethAddress()\n        internal\n        view\n        returns (address wethAddress)\n    {\n        return WETH_ADDRESS;\n    }\n\n    /// @dev Overridable way to get the `UniswapExchangeFactory` address.\n    /// @return uniswapAddress The `UniswapExchangeFactory` address.\n    function _getUniswapExchangeFactoryAddress()\n        internal\n        view\n        returns (address uniswapAddress)\n    {\n        return UNISWAP_EXCHANGE_FACTORY_ADDRESS;\n    }\n\n    /// @dev Overridable way to get the `UniswapV2Router01` address.\n    /// @return uniswapRouterAddress The `UniswapV2Router01` address.\n    function _getUniswapV2Router01Address()\n        internal\n        view\n        returns (address uniswapRouterAddress)\n    {\n        return UNISWAP_V2_ROUTER_01_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the Eth2Dai `MatchingMarket` contract.\n    /// @return eth2daiAddress The Eth2Dai `MatchingMarket` contract.\n    function _getEth2DaiAddress()\n        internal\n        view\n        returns (address eth2daiAddress)\n    {\n        return ETH2DAI_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the `ERC20BridgeProxy` contract.\n    /// @return erc20BridgeProxyAddress The `ERC20BridgeProxy` contract.\n    function _getERC20BridgeProxyAddress()\n        internal\n        view\n        returns (address erc20BridgeProxyAddress)\n    {\n        return ERC20_BRIDGE_PROXY_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the `Dai` contract.\n    /// @return daiAddress The `Dai` contract.\n    function _getDaiAddress()\n        internal\n        view\n        returns (address daiAddress)\n    {\n        return DAI_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the `Chai` contract.\n    /// @return chaiAddress The `Chai` contract.\n    function _getChaiAddress()\n        internal\n        view\n        returns (address chaiAddress)\n    {\n        return CHAI_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the 0x `DevUtils` contract address.\n    /// @return devUtils The 0x `DevUtils` contract address.\n    function _getDevUtilsAddress()\n        internal\n        view\n        returns (address devUtils)\n    {\n        return DEV_UTILS_ADDRESS;\n    }\n\n    /// @dev Overridable way to get the DyDx contract.\n    /// @return exchange The DyDx exchange contract.\n    function _getDydxAddress()\n        internal\n        view\n        returns (address dydxAddress)\n    {\n        return DYDX_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the GST2 contract address.\n    /// @return gst The GST contract.\n    function _getGstAddress()\n        internal\n        view\n        returns (address gst)\n    {\n        return GST_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the GST Collector address.\n    /// @return collector The GST collector address.\n    function _getGstCollectorAddress()\n        internal\n        view\n        returns (address collector)\n    {\n        return GST_COLLECTOR_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the mStable mUSD address.\n    /// @return musd The mStable mUSD address.\n    function _getMUsdAddress()\n        internal\n        view\n        returns (address musd)\n    {\n        return MUSD_ADDRESS;\n    }\n\n    /// @dev An overridable way to retrieve the Mooniswap registry address.\n    /// @return registry The Mooniswap registry address.\n    function _getMooniswapAddress()\n        internal\n        view\n        returns (address)\n    {\n        return MOONISWAP_REGISTRY;\n    }\n\n    /// @dev An overridable way to retrieve the DODO Registry contract address.\n    /// @return registry The DODO Registry contract address.\n    function _getDODORegistryAddress()\n        internal\n        view\n        returns (address)\n    {\n        return DODO_REGISTRY;\n    }\n\n    /// @dev An overridable way to retrieve the DODO Helper contract address.\n    /// @return registry The DODO Helper contract address.\n    function _getDODOHelperAddress()\n        internal\n        view\n        returns (address)\n    {\n        return DODO_HELPER;\n    }\n}\n",
        "../interfaces/IUniswapExchangeFactory.sol": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\nimport \"./IUniswapExchange.sol\";\n\n\ninterface IUniswapExchangeFactory {\n\n    /// @dev Get the exchange for a token.\n    /// @param tokenAddress The address of the token contract.\n    function getExchange(address tokenAddress)\n        external\n        view\n        returns (address);\n}\n",
        "../interfaces/IUniswapExchange.sol": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\ninterface IUniswapExchange {\n\n    /// @dev Buys at least `minTokensBought` tokens with ETH and transfer them\n    ///      to `recipient`.\n    /// @param minTokensBought The minimum number of tokens to buy.\n    /// @param deadline Time when this order expires.\n    /// @param recipient Who to transfer the tokens to.\n    /// @return tokensBought Amount of tokens bought.\n    function ethToTokenTransferInput(\n        uint256 minTokensBought,\n        uint256 deadline,\n        address recipient\n    )\n        external\n        payable\n        returns (uint256 tokensBought);\n\n    /// @dev Buys at least `minEthBought` ETH with tokens.\n    /// @param tokensSold Amount of tokens to sell.\n    /// @param minEthBought The minimum amount of ETH to buy.\n    /// @param deadline Time when this order expires.\n    /// @return ethBought Amount of tokens bought.\n    function tokenToEthSwapInput(\n        uint256 tokensSold,\n        uint256 minEthBought,\n        uint256 deadline\n    )\n        external\n        returns (uint256 ethBought);\n\n    /// @dev Buys at least `minTokensBought` tokens with the exchange token\n    ///      and transfer them to `recipient`.\n    /// @param minTokensBought The minimum number of tokens to buy.\n    /// @param minEthBought The minimum amount of intermediate ETH to buy.\n    /// @param deadline Time when this order expires.\n    /// @param recipient Who to transfer the tokens to.\n    /// @param toTokenAddress The token being bought.\n    /// @return tokensBought Amount of tokens bought.\n    function tokenToTokenTransferInput(\n        uint256 tokensSold,\n        uint256 minTokensBought,\n        uint256 minEthBought,\n        uint256 deadline,\n        address recipient,\n        address toTokenAddress\n    )\n        external\n        returns (uint256 tokensBought);\n}\n",
        "../interfaces/IERC20Bridge.sol": "/*\n\n  Copyright 2019 ZeroEx Intl.\n\n  Licensed under the Apache License, Version 2.0 (the \"License\");\n  you may not use this file except in compliance with the License.\n  You may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\n  Unless required by applicable law or agreed to in writing, software\n  distributed under the License is distributed on an \"AS IS\" BASIS,\n  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  See the License for the specific language governing permissions and\n  limitations under the License.\n\n*/\n\npragma solidity ^0.5.9;\n\n\ncontract IERC20Bridge {\n\n    /// @dev Result of a successful bridge call.\n    bytes4 constant internal BRIDGE_SUCCESS = 0xdc1600f3;\n\n    /// @dev Emitted when a trade occurs.\n    /// @param inputToken The token the bridge is converting from.\n    /// @param outputToken The token the bridge is converting to.\n    /// @param inputTokenAmount Amount of input token.\n    /// @param outputTokenAmount Amount of output token.\n    /// @param from The `from` address in `bridgeTransferFrom()`\n    /// @param to The `to` address in `bridgeTransferFrom()`\n    event ERC20BridgeTransfer(\n        address inputToken,\n        address outputToken,\n        uint256 inputTokenAmount,\n        uint256 outputTokenAmount,\n        address from,\n        address to\n    );\n\n    /// @dev Transfers `amount` of the ERC20 `tokenAddress` from `from` to `to`.\n    /// @param tokenAddress The address of the ERC20 token to transfer.\n    /// @param from Address to transfer asset from.\n    /// @param to Address to transfer asset to.\n    /// @param amount Amount of asset to transfer.\n    /// @param bridgeData Arbitrary asset data needed by the bridge contract.\n    /// @return success The magic bytes `0xdc1600f3` if successful.\n    function bridgeTransferFrom(\n        address tokenAddress,\n        address from,\n        address to,\n        uint256 amount,\n        bytes calldata bridgeData\n    )\n        external\n        returns (bytes4 success);\n}\n"
    },
    "compiler": {
        "name": "solc",
        "version": "0.5.17+commit.d19bba13",
        "settings": {
            "remappings": [
                "@0x/contracts-utils=/home/runner/work/protocol/protocol/contracts/asset-proxy/node_modules/@0x/contracts-utils",
                "@0x/contracts-erc1155=/home/runner/work/protocol/protocol/contracts/asset-proxy/node_modules/@0x/contracts-erc1155",
                "@0x/contracts-erc20=/home/runner/work/protocol/protocol/contracts/asset-proxy/node_modules/@0x/contracts-erc20",
                "@0x/contracts-exchange-libs=/home/runner/work/protocol/protocol/contracts/asset-proxy/node_modules/@0x/contracts-exchange-libs"
            ],
            "optimizer": {
                "enabled": true,
                "runs": 1000000,
                "details": {
                    "yul": true,
                    "deduplicate": true,
                    "cse": true,
                    "constantOptimizer": true
                }
            },
            "outputSelection": {
                "*": {
                    "*": [
                        "abi",
                        "devdoc",
                        "evm.bytecode.object",
                        "evm.bytecode.sourceMap",
                        "evm.deployedBytecode.object",
                        "evm.deployedBytecode.sourceMap"
                    ]
                }
            },
            "evmVersion": "istanbul"
        }
    },
    "chains": {}
}
