{
  "contractName": "RedemptionScript",
  "abi": [
    {
      "inputs": [
        {
          "internalType": "address",
          "name": "_VendingMachine",
          "type": "address"
        },
        {
          "internalType": "address",
          "name": "_TBTCToken",
          "type": "address"
        },
        {
          "internalType": "address",
          "name": "_FeeRebateToken",
          "type": "address"
        }
      ],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "constructor"
    },
    {
      "constant": false,
      "inputs": [
        {
          "internalType": "address",
          "name": "_from",
          "type": "address"
        },
        {
          "internalType": "uint256",
          "name": "_amount",
          "type": "uint256"
        },
        {
          "internalType": "address",
          "name": "",
          "type": "address"
        },
        {
          "internalType": "bytes",
          "name": "_extraData",
          "type": "bytes"
        }
      ],
      "name": "receiveApproval",
      "outputs": [],
      "payable": false,
      "stateMutability": "nonpayable",
      "type": "function"
    }
  ],
  "metadata": "{\"compiler\":{\"version\":\"0.5.17+commit.d19bba13\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_VendingMachine\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_TBTCToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_FeeRebateToken\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"receiveApproval\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"details\":\"Wrapper script for VendingMachine.tbtcToBtc This contract implements receiveApproval() and can therefore use approveAndCall(). This pattern combines TBTC Token approval and vendingMachine.tbtcToBtc() in a single transaction.\",\"methods\":{\"receiveApproval(address,uint256,address,bytes)\":{\"details\":\"Implements the approveAndCall receiver interface.\",\"params\":{\"_amount\":\"Approved TBTC amount for the transfer.\",\"_extraData\":\"Encoded function call to `VendingMachine.tbtcToBtc`.\",\"_from\":\"The owner of the token who approved them for transfer.\"}}}},\"userdoc\":{\"methods\":{\"receiveApproval(address,uint256,address,bytes)\":{\"notice\":\"Receives approval for a TBTC transfer, and calls `VendingMachine.tbtcToBtc` for a user.\"}},\"notice\":\"A one-click script for redeeming TBTC into BTC.\"}},\"settings\":{\"compilationTarget\":{\"/home/runner/work/tbtc/tbtc/solidity/contracts/scripts/RedemptionScript.sol\":\"RedemptionScript\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"/home/runner/work/tbtc/tbtc/solidity/contracts/DepositLog.sol\":{\"keccak256\":\"0xd2422abaf64bf2d28f4c0548bc31c3d0e4c5f3e4414486c149b773bea0c9db0a\",\"urls\":[\"bzz-raw://c4b0e3caea108ce67da5922906753dc1a1f87cee923e7c32260239150f2152bb\",\"dweb:/ipfs/QmcHcftf4M6ZyuFG725QiFGHuAtz6zDQZ9HCEaoP5Wb6Fd\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/deposit/Deposit.sol\":{\"keccak256\":\"0x4e25c6bfe874c5254659e99b5d87ad0bd6299468106c8f955e973a0431367dec\",\"urls\":[\"bzz-raw://c54c7e956fee91813946745f23d11062a9dd2c07d916979871f7468509295de4\",\"dweb:/ipfs/QmQ1qFjzq9uY7SmdUqzwNM7z8AAnCbji2joqkJYJSBaJyW\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/deposit/DepositFunding.sol\":{\"keccak256\":\"0xe223f4e039e347d3eec8eea8d30d6f87f25ab3f8839e96b5da608c6a012db2c2\",\"urls\":[\"bzz-raw://48435948a4b232a3c610f7ac51e5c87a27aa10f92775bc95cd2068dd07b69a70\",\"dweb:/ipfs/Qmd7PeN1uovU8BqyrPuLkKf4U1DENt9S7hFr6G5cXFamim\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/deposit/DepositLiquidation.sol\":{\"keccak256\":\"0x6ec98705ac0cfc20f2e94069ba88c74816c40283c47b3086cf619b69d8a15379\",\"urls\":[\"bzz-raw://981e7e1ababfe4bb7bb35251679f59d188348c416af29822794011a0e48f2cd3\",\"dweb:/ipfs/QmTpPQCYP3qzKdcMBLBZGRSM2X6rgR1CZmYDQ7SHP4pjrb\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/deposit/DepositRedemption.sol\":{\"keccak256\":\"0xe40c0cbb443715c4f587b78f568348276fabae9a2f77645596367a1f65b1fae5\",\"urls\":[\"bzz-raw://310d07df39ad769b5ffca044a1a589686268d72ac36d568360da3a4a9ab16f93\",\"dweb:/ipfs/QmT9stQ2AVkF7i9nvDSTswhD6EkfNHVCtTmRENsVqYxwso\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/deposit/DepositStates.sol\":{\"keccak256\":\"0x0b407fe4cfa56771c7cb0280e58c23e6c79089bb0f39ec9af83855103cfadce0\",\"urls\":[\"bzz-raw://b06c9ff8c10125cd7dcee7167fd081c95248c97c699a4dfc92bf65d68774f5f1\",\"dweb:/ipfs/QmcdTkj1XtJcPhF9pxr56xV4DW3SxGaaiE5PeGxbYVoHL3\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/deposit/DepositUtils.sol\":{\"keccak256\":\"0xc18e532fc384f45567abcf7fbe7bccb885308d63ffeed41d9cf845573a289b98\",\"urls\":[\"bzz-raw://7250e8fce13326313e64d2f24e093bd51c9fdba939b8370f64a1fe820814275b\",\"dweb:/ipfs/QmVfX5w4xN6gxoqbdgPeeTbBvFtxxaNYWSknSY7JDtve2b\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/deposit/OutsourceDepositLogging.sol\":{\"keccak256\":\"0x8bddca84b4106ea5d865b5e19c0d49f3dc94a7e614c7403ae05074eda01d6ee9\",\"urls\":[\"bzz-raw://65b05f6e04ae46a16194db335ad21dd806d0b07ad571a126b6981896890c8a4c\",\"dweb:/ipfs/QmTF4RgELhXX7pooNKwW8qNY7Sr7dFY7vfueApjTMa99jt\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/interfaces/ITBTCSystem.sol\":{\"keccak256\":\"0xd8530ab1baddbdfbba6c1b03e547375afe79493b9948d645f94fc0da12ec953b\",\"urls\":[\"bzz-raw://713285a0a4d865a37f3770ce848c20f7277e1540c0a8aa43c2ae0966a7c3df9a\",\"dweb:/ipfs/QmaPiXxvySt9UDmQtVGidh8TQ4XJdxY2X61rEBd8346ELi\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/interfaces/ITokenRecipient.sol\":{\"keccak256\":\"0x4ac6830ad44d0b0d70ebabc60150e9c915c7c0bd0129ef868d5d2cd8da0c32bd\",\"urls\":[\"bzz-raw://a5c6465285add41f07a951f90405800a8802e323ea11e9c7bdb5625ce109c7f7\",\"dweb:/ipfs/QmRf7B4WxsS7gbSwUotgQM633BQc2ye7rhYC1RNVFamBfp\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/scripts/RedemptionScript.sol\":{\"keccak256\":\"0x90391e5b5359ba8c9aac2f97b668818dcf54e10b73c41488aa21b763fb83ff13\",\"urls\":[\"bzz-raw://b2c0e4ea47249af3552e026e0e7be58a991b7d0526d9ae589660e0ab5e35048b\",\"dweb:/ipfs/QmPyarLBv3pfGoKeNktB5deKKCSZy7neQSk9PrDsEEJAJJ\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/system/DepositFactoryAuthority.sol\":{\"keccak256\":\"0xd8e81ec58dea6a6bcc554e8c7e6c58898ab11a410c3f61224330cbe833992add\",\"urls\":[\"bzz-raw://9d2b23cf1e2f98eb77acf6ae62933e48494113e1d6091146459fd79a635f1dcf\",\"dweb:/ipfs/QmPK3nTmcrScDavDSXGHvonhfik3BJ55qhwSnUmhzL5QUE\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/system/FeeRebateToken.sol\":{\"keccak256\":\"0x3d9980b4b18be7e69364b93581d86d08dd2c66fc76b2f9f0af0b4911dc648318\",\"urls\":[\"bzz-raw://751dae1cd68c285a22b513d515074eb6704e11e00ba8196f360d47dc8551dd86\",\"dweb:/ipfs/QmRe5u8bjSd2CMvjgWMzpeea3VdcqEGwAP91zvjxgur8o8\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/system/TBTCConstants.sol\":{\"keccak256\":\"0x74833fb25cf9f24716d563c8fad0fd6172d03577dc85ab4271ca4754285ee915\",\"urls\":[\"bzz-raw://62d37b71546ea52f0c86170b588b021a488785e8570f904f0d2bcfecee93f6a7\",\"dweb:/ipfs/QmePuD631VYpEproKbap8cPXmWeb5mYjU6bwEWnxKCVWbz\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/system/TBTCDepositToken.sol\":{\"keccak256\":\"0xd9238bbd83f5352706426103a0708ad7c00ffbd90340a4b3bab03d2c5371e48b\",\"urls\":[\"bzz-raw://f1fc94f00aeabd49bd0f8ecf372213e83c949454c28fa672a46dd12d9a0b4311\",\"dweb:/ipfs/QmaCzqi2g4GSvzHDDES61FauDmdTGGyZrCkK1BdxpMqYa3\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/system/TBTCSystemAuthority.sol\":{\"keccak256\":\"0xc072c71402f122e3ae148000b95559169cb39b8752977817f4f88b372e7d77dd\",\"urls\":[\"bzz-raw://9c91b71602bf36f66d6ab24156777a2ef18c027f09055232011f9012387e6c70\",\"dweb:/ipfs/QmYAEZ8ithnhVcdCt76mqeJg6P8ZY3VejsV7pQNvMMFqc2\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/system/TBTCToken.sol\":{\"keccak256\":\"0x167b07029df8d350996d7f82d853437d1a2562401eeac98037c2eb4c5f295319\",\"urls\":[\"bzz-raw://7d2601ac8dcd5d59b3e479a61262de2162c96ed7ad1cd161331e2e4500b8346a\",\"dweb:/ipfs/QmWVjBSvHFg9W5zsSxgdpNSYKgfLa28fr3mPjjKQaDBxmk\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/system/VendingMachine.sol\":{\"keccak256\":\"0x26caaccd71277d1807d40553f4e7291307d4db9c292bc28a9d8cbee94b5c3e40\",\"urls\":[\"bzz-raw://b7ec73a87fe902bfc5d0fcda5fcc16d2dc025e685fc7b7876ec1a1da65cf0ede\",\"dweb:/ipfs/QmcBkU6Ze8T3ewqZZmUiniTKZkVaQTaNFejXXRgvfiTrPE\"]},\"/home/runner/work/tbtc/tbtc/solidity/contracts/system/VendingMachineAuthority.sol\":{\"keccak256\":\"0x7ad8a2cee5e6bbc187d04b147dc0d2bc2ae12bb8c3680870be9013dd5543bfd6\",\"urls\":[\"bzz-raw://733f2370c788437b0034c40a8df07f4714009769ed8134a9c656e2a103996687\",\"dweb:/ipfs/Qma9LAGQDzyUvsbhLx3FUKRCx3FmnoZuMxG4SUdjLr8bRm\"]},\"@keep-network/keep-ecdsa/contracts/api/IBondedECDSAKeep.sol\":{\"keccak256\":\"0x8f1edc0a2dfb4d167d190989ebc1c4256664e50ec1f82dfaeb25fa5d4a76a35a\",\"urls\":[\"bzz-raw://e815868907cc082fee1e3964be7de12da2161863d68dd1532a74e3a97bacf533\",\"dweb:/ipfs/Qmd8DqutKSwxh38WWA1ydftNkiAxSD9sqxa7qf1asHKA8c\"]},\"@summa-tx/bitcoin-spv-sol/contracts/BTCUtils.sol\":{\"keccak256\":\"0x461cc52e40ba53e646f5c9505b992baa3d5b3c98ae5718561e61b3bc6c726d52\",\"urls\":[\"bzz-raw://90cf2e608b660671642a616ec044e2a39e8ceb7079315b6133ec978c47af9f98\",\"dweb:/ipfs/QmX4hyYS99RYWiQ7BwLXuvQpU5x62YbjJWLgYFwrPkYbzT\"]},\"@summa-tx/bitcoin-spv-sol/contracts/BytesLib.sol\":{\"keccak256\":\"0x43451fdb4c4d55c01122411a4cf89a5c544c2bd4b646ee1d1f306626275324bf\",\"urls\":[\"bzz-raw://db93f07c32fa294d416aaab1b19a205772f2a3fa573fd380e5641e7770193ccf\",\"dweb:/ipfs/QmVE4y8cFKWZGKEfTM9Q3YreAArpMTTALHNr2tcvcNDnbi\"]},\"@summa-tx/bitcoin-spv-sol/contracts/CheckBitcoinSigs.sol\":{\"keccak256\":\"0x2fcbfa2440f69e346d5e14d960b14498f6484f83713fe7cec1ecf4abea3835a1\",\"urls\":[\"bzz-raw://4a385ef55a53dd0dcd1b687a47dbf6785580883a0be0cb10c617c338a35f3a8b\",\"dweb:/ipfs/QmZp9AT146beL3SoETJCWsJ4zzAZQavy9oGCYPiwAofEtq\"]},\"@summa-tx/bitcoin-spv-sol/contracts/SafeMath.sol\":{\"keccak256\":\"0x22d34c04c68c2a77ee83e2ef3756f6e6bad6ad675560d777e612315d7eb83935\",\"urls\":[\"bzz-raw://b642c61be1d34e153e4f9cc139291fa26f4ecf31a3acc5b960aad20f4f689eeb\",\"dweb:/ipfs/QmWADdVTCSyvtgb76AxFFkAr9h9jbY57Mj5X6xiEqCqmMu\"]},\"@summa-tx/bitcoin-spv-sol/contracts/ValidateSPV.sol\":{\"keccak256\":\"0x9af3b3f36de63e95977f09548617989e391b3c511cf0383ee35cefd5da7d3bfd\",\"urls\":[\"bzz-raw://97ce025c7d18540e4c24578db61cc5e33828be8e9a82b5cb5f46c99212f75ed1\",\"dweb:/ipfs/QmRrdWnd95rgCZzeaNiU4KUcGe1j7oDBj7LatpXhUmjbEE\"]},\"openzeppelin-solidity/contracts/drafts/Counters.sol\":{\"keccak256\":\"0x5eb69360d3441ab2ee799bd7c007cccbffb0896f12b2dfe1456193e2aa180a11\",\"urls\":[\"bzz-raw://072e8b5a1b5acfc2acba9b6fb87d1dc57065aad44572617ad46b014074969eb3\",\"dweb:/ipfs/QmVTDHUriaxBJqiWCWgWC8vYaYYfXSz883LsowzTx1DcpK\"]},\"openzeppelin-solidity/contracts/introspection/ERC165.sol\":{\"keccak256\":\"0xac2eacd7e7762e275442f28f21d821544df5aae2ed7698af13be8c41b7005e2e\",\"urls\":[\"bzz-raw://8bdbefb642e7b08535c66bbf074e576cfef2300cdf910c1e0b211f6393833a28\",\"dweb:/ipfs/QmQhfx2Ufr8a2gFXm3KogL66xGgAuAWMwcamkWFKGG6Vya\"]},\"openzeppelin-solidity/contracts/introspection/IERC165.sol\":{\"keccak256\":\"0x661553e43d7c4fbb2de504e5999fd5c104d367488350ed5bf023031bd1ba5ac5\",\"urls\":[\"bzz-raw://b40442c5b350b57b88a081a1eacd2bac962d4ecc1f029f5447a18986f08f6f14\",\"dweb:/ipfs/QmV7wjtRf11ibUHh4g8JjuhMpy68pPhV95L2y46UBoRfsZ\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x4ccf2d7b51873db1ccfd54ca2adae5eac3b184f9699911ed4490438419f1c690\",\"urls\":[\"bzz-raw://d62d769b2219d5de39013093412623e624fa887f871826ea3bae6052ee893610\",\"dweb:/ipfs/QmV3yVktya1s617QmuzQR2CfuJgUi3dR2xEZY9ecmqZ2G1\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x852793a3c2f86d336a683b30d688ec3dcfc57451af5a2bf5975cda3b7191a901\",\"urls\":[\"bzz-raw://4f5b57664069671648fb81f55b0082faecdf1b2f159eec6b1fa6cef9b7d73bc5\",\"dweb:/ipfs/QmcyytaLs7zFdb4Uu7C5PmQRhQdB3wA3fUdkV6mkYfdDFH\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol\":{\"keccak256\":\"0xc61b3603089b09a730d8ca72e9133a496cc4405da40e9b87c12f073245d774bf\",\"urls\":[\"bzz-raw://de8bb0003d53de236913f0e0102e7a9d015e02098f2495edd000f207fe2be2f4\",\"dweb:/ipfs/QmbtwNwAJEehWWL7yGGyyMoenQvcqtz91pqLgQPpLRoLYC\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0x90e8c2521653bbb1768b05889c5760031e688d9cd361f167489b89215e201b95\",\"urls\":[\"bzz-raw://d0abb99bb8bfc2bc0a89902b8ed1dc0442ad08cc78cee64c291b3df6a27bcccc\",\"dweb:/ipfs/QmP5NaEwZthQeM2ESz4WTT3osrP7jhbvu7ocbttBi2JAw6\"]},\"openzeppelin-solidity/contracts/token/ERC721/ERC721.sol\":{\"keccak256\":\"0xf151df411bbf4eaef1fc8e8480cd10c2cd985f1a36517e63981517610213efc1\",\"urls\":[\"bzz-raw://2a277b3cc3a1a03af5c039bc75cd16bb2d23b529cb2564cc0bea1b1e0eb4dd68\",\"dweb:/ipfs/QmNRxggY8qmjjuLnxggRqE8uBueuCktLwi9YYHagWoaEJ8\"]},\"openzeppelin-solidity/contracts/token/ERC721/ERC721Metadata.sol\":{\"keccak256\":\"0xe5e28b1a405164faa98f8ecd8ed2b00907b89e3d58b2b2bb8ac8b12bc5714489\",\"urls\":[\"bzz-raw://0d5d3f0caa7e7ec91f8a2894e1a6a3513a0c79aa91a498ebf8fdbdd07c12286f\",\"dweb:/ipfs/QmP7r4jQMRxXb5JHy5V9bgMz5FmTezcSDd7ivyzJN88pTR\"]},\"openzeppelin-solidity/contracts/token/ERC721/IERC721.sol\":{\"keccak256\":\"0xce48937a8007c580b8e2e35705738c922dd17540de89ebee6df06d2917a3f9fc\",\"urls\":[\"bzz-raw://1d117265103ee3efcd454d3aafb3e79a115f9bca6dec78a1229558eb30d14d05\",\"dweb:/ipfs/QmTm5Z1c7zzPiG3Cfj1eBMB23AeiEFGgvmTFQVaeEWXVCw\"]},\"openzeppelin-solidity/contracts/token/ERC721/IERC721Metadata.sol\":{\"keccak256\":\"0x2b2b99dc7fe8fcd1f9427d00822b99cbc683dc21f5dd7532bd7e2281fd2c2ca2\",\"urls\":[\"bzz-raw://a8024c00e34efaf328f9592e76823c79f25fa0f6006bdf4a1e7fea204afd4773\",\"dweb:/ipfs/QmZns9jTr7843njq3J2iL2LLoWXK5mdzN1bDGd9GL3ahhD\"]},\"openzeppelin-solidity/contracts/token/ERC721/IERC721Receiver.sol\":{\"keccak256\":\"0xadbfb7028fb0f851dc848a48b9e54e7c89ffd2c2edc12fa4ba9bb383dfaa83d9\",\"urls\":[\"bzz-raw://90dceab42713246639100b87d6650037d68e4a2ab2dd4b5768c3ed35d6b3a4a0\",\"dweb:/ipfs/QmQ42UW5nchMoYP9bU9F1AJga5chG8j92fCPkURpiDKsCu\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0xf3358e5819ca73357abd6c90bdfffd0474af54364897f6b3e3234c4b71fbe9a1\",\"urls\":[\"bzz-raw://75ae8d04454d1511a2ed986cc8585736f05c5c25280683b3d24712a9f414a4bf\",\"dweb:/ipfs/Qmb3kNCoBUZdah1AgBBD4zMk898j5Qw8ahT1w5cCMYp5Y3\"]}},\"version\":1}",
  "bytecode": "0x608060405234801561001057600080fd5b5060405161051d38038061051d8339818101604052606081101561003357600080fd5b5080516020820151604090920151600180546001600160a01b039384166001600160a01b031991821617909155600080549484169482169490941790935560028054929091169190921617905561048e8061008f6000396000f3fe608060405234801561001057600080fd5b506004361061002b5760003560e01c80638f4ffcb114610030575b600080fd5b6100f56004803603608081101561004657600080fd5b6001600160a01b03823581169260208101359260408201359092169181019060808101606082013564010000000081111561008057600080fd5b82018360208201111561009257600080fd5b803590602001918460018302840111640100000000831117156100b457600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295506100f7945050505050565b005b6000546001600160a01b031633146101405760405162461bcd60e51b815260040180806020018281038252602c8152602001806103fa602c913960400191505060405180910390fd5b60008054604080516323b872dd60e01b81526001600160a01b03888116600483015230602483015260448201889052915191909216926323b872dd92606480820193602093909283900390910190829087803b15801561019f57600080fd5b505af11580156101b3573d6000803e3d6000fd5b505050506040513d60208110156101c957600080fd5b5050600080546001546040805163095ea7b360e01b81526001600160a01b039283166004820152602481018890529051919092169263095ea7b392604480820193602093909283900390910190829087803b15801561022757600080fd5b505af115801561023b573d6000803e3d6000fd5b505050506040513d602081101561025157600080fd5b5050602081015160ff198116906001600160e01b03191663be138da760e01b146102ac5760405162461bcd60e51b81526004018080602001828103825260348152602001806104266034913960400191505060405180910390fd5b60015460405183516000926060926001600160a01b0390911691869190819060208401908083835b602083106102f35780518252601f1990920191602091820191016102d4565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114610355576040519150601f19603f3d011682016040523d82523d6000602084013e61035a565b606091505b5090925090506044810180836103ee5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156103b357818101518382015260200161039b565b50505050905090810190601f1680156103e05780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50505050505050505056fe4f6e6c7920746f6b656e20636f6e74726163742063616e2063616c6c2072656365697665417070726f76616c426164205f657874726144617461207369676e61747572652e2043616c6c206d75737420626520746f2074627463546f4274632ea265627a7a72315820a8722a8b9014fa22d2f4a15a76579028db3d271c112eecc41e11c2f7d7380ed864736f6c63430005110032",
  "deployedBytecode": "0x608060405234801561001057600080fd5b506004361061002b5760003560e01c80638f4ffcb114610030575b600080fd5b6100f56004803603608081101561004657600080fd5b6001600160a01b03823581169260208101359260408201359092169181019060808101606082013564010000000081111561008057600080fd5b82018360208201111561009257600080fd5b803590602001918460018302840111640100000000831117156100b457600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295506100f7945050505050565b005b6000546001600160a01b031633146101405760405162461bcd60e51b815260040180806020018281038252602c8152602001806103fa602c913960400191505060405180910390fd5b60008054604080516323b872dd60e01b81526001600160a01b03888116600483015230602483015260448201889052915191909216926323b872dd92606480820193602093909283900390910190829087803b15801561019f57600080fd5b505af11580156101b3573d6000803e3d6000fd5b505050506040513d60208110156101c957600080fd5b5050600080546001546040805163095ea7b360e01b81526001600160a01b039283166004820152602481018890529051919092169263095ea7b392604480820193602093909283900390910190829087803b15801561022757600080fd5b505af115801561023b573d6000803e3d6000fd5b505050506040513d602081101561025157600080fd5b5050602081015160ff198116906001600160e01b03191663be138da760e01b146102ac5760405162461bcd60e51b81526004018080602001828103825260348152602001806104266034913960400191505060405180910390fd5b60015460405183516000926060926001600160a01b0390911691869190819060208401908083835b602083106102f35780518252601f1990920191602091820191016102d4565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114610355576040519150601f19603f3d011682016040523d82523d6000602084013e61035a565b606091505b5090925090506044810180836103ee5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156103b357818101518382015260200161039b565b50505050905090810190601f1680156103e05780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50505050505050505056fe4f6e6c7920746f6b656e20636f6e74726163742063616e2063616c6c2072656365697665417070726f76616c426164205f657874726144617461207369676e61747572652e2043616c6c206d75737420626520746f2074627463546f4274632ea265627a7a72315820a8722a8b9014fa22d2f4a15a76579028db3d271c112eecc41e11c2f7d7380ed864736f6c63430005110032",
  "sourceMap": "760:2402:17:-;;;938:285;8:9:-1;5:2;;;30:1;27;20:12;5:2;938:285:17;;;;;;;;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;938:285:17;;;;;;;;;;;1067:14;:48;;-1:-1:-1;;;;;1067:48:17;;;-1:-1:-1;;;;;;1067:48:17;;;;;;;:14;1125:33;;;;;;;;;;;;;;;1168:14;:48;;;;;;;;;;;;;760:2402;;;;;;",
  "deployedSourceMap": "760:2402:17:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;760:2402:17;;;;;;;;;;;;;;;;;;;1613:1547;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;1613:1547:17;;;;;;;;;;;;;;;;;;;;;;;;;;;;21:11:-1;5:28;;2:2;;;46:1;43;36:12;2:2;1613:1547:17;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;1613:1547:17;;;;;;100:9:-1;95:1;81:12;77:20;67:8;63:35;60:50;39:11;25:12;22:29;11:107;8:2;;;131:1;128;121:12;8:2;1613:1547:17;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30:3:-1;22:6;14;1:33;99:1;81:16;;74:27;;;;-1:-1;1613:1547:17;;-1:-1:-1;1613:1547:17;;-1:-1:-1;;;;;1613:1547:17:i;:::-;;;1859:9;;-1:-1:-1;;;;;1859:9:17;1837:10;:32;1816:123;;;;-1:-1:-1;;;1816:123:17;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1950:9;;;:53;;;-1:-1:-1;;;1950:53:17;;-1:-1:-1;;;;;1950:53:17;;;;;;;1988:4;1950:53;;;;;;;;;;;;:9;;;;;:22;;:53;;;;;;;;;;;;;;;;;;:9;:53;;;5:2:-1;;;;30:1;27;20:12;5:2;1950:53:17;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1950:53:17;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;2013:9:17;;;;2039:14;2013:51;;;-1:-1:-1;;;2013:51:17;;-1:-1:-1;;;;;2039:14:17;;;2013:51;;;;;;;;;;;;:9;;;;;:17;;:51;;;;;1950:53;;2013:51;;;;;;;;;;;:9;:51;;;5:2:-1;;;;30:1;27;20:12;5:2;2013:51:17;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2013:51:17;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;2013:51:17;2216:21;;2210:28;-1:-1:-1;;2206:44:17;;;-1:-1:-1;;;;;;2290:54:17;-1:-1:-1;;;2290:54:17;2269:153;;;;-1:-1:-1;;;2269:153:17;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2679:14;;2671:40;;;;2618:12;;2632:23;;-1:-1:-1;;;;;2679:14:17;;;;2700:10;;2671:40;;;;;;;;;;36:153:-1;66:2;61:3;58:11;36:153;;176:10;;164:23;;-1:-1;;139:12;;;;98:2;89:12;;;;114;36:153;;;274:1;267:3;263:2;259:12;254:3;250:22;246:30;315:4;311:9;305:3;299:10;295:26;356:4;350:3;344:10;340:21;389:7;380;377:20;372:3;365:33;3:399;;;2671:40:17;;;;;;;;;;;;;;;;;;;;;;;;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;-1:-1;2617:94:17;;-1:-1:-1;2617:94:17;-1:-1:-1;3097:4:17;3081:21;;;2617:94;3122:31;;;;-1:-1:-1;;;3122:31:17;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;;12:14;3122:31:17;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1613:1547;;;;;;;;:::o",
  "source": "pragma solidity 0.5.17;\n\nimport {ITokenRecipient} from \"../interfaces/ITokenRecipient.sol\";\nimport {TBTCDepositToken} from \"../system/TBTCDepositToken.sol\";\nimport {TBTCToken} from \"../system/TBTCToken.sol\";\nimport {FeeRebateToken} from \"../system/FeeRebateToken.sol\";\nimport {VendingMachine} from \"../system/VendingMachine.sol\";\nimport {Deposit} from \"../deposit/Deposit.sol\";\nimport {BytesLib} from \"@summa-tx/bitcoin-spv-sol/contracts/BytesLib.sol\";\n\n/// @notice A one-click script for redeeming TBTC into BTC.\n/// @dev Wrapper script for VendingMachine.tbtcToBtc\n/// This contract implements receiveApproval() and can therefore use\n/// approveAndCall(). This pattern combines TBTC Token approval and\n/// vendingMachine.tbtcToBtc() in a single transaction.\ncontract RedemptionScript is ITokenRecipient {\n    using BytesLib for bytes;\n\n    TBTCToken tbtcToken;\n    VendingMachine vendingMachine;\n    FeeRebateToken feeRebateToken;\n\n    constructor(\n        address _VendingMachine,\n        address _TBTCToken,\n        address _FeeRebateToken\n    ) public {\n        vendingMachine = VendingMachine(_VendingMachine);\n        tbtcToken = TBTCToken(_TBTCToken);\n        feeRebateToken = FeeRebateToken(_FeeRebateToken);\n    }\n\n    /// @notice Receives approval for a TBTC transfer, and calls `VendingMachine.tbtcToBtc` for a user.\n    /// @dev Implements the approveAndCall receiver interface.\n    /// @param _from The owner of the token who approved them for transfer.\n    /// @param _amount Approved TBTC amount for the transfer.\n    /// @param _extraData Encoded function call to `VendingMachine.tbtcToBtc`.\n    function receiveApproval(\n        address _from,\n        uint256 _amount,\n        address,\n        bytes memory _extraData\n    ) public {\n        // not external to allow bytes memory parameters\n        require(\n            msg.sender == address(tbtcToken),\n            \"Only token contract can call receiveApproval\"\n        );\n\n        tbtcToken.transferFrom(_from, address(this), _amount);\n        tbtcToken.approve(address(vendingMachine), _amount);\n\n        // Verify _extraData is a call to tbtcToBtc.\n        bytes4 functionSignature;\n        assembly {\n            functionSignature := and(mload(add(_extraData, 0x20)), not(0xff))\n        }\n        require(\n            functionSignature == vendingMachine.tbtcToBtc.selector,\n            \"Bad _extraData signature. Call must be to tbtcToBtc.\"\n        );\n\n        // We capture the `returnData` in order to forward any nested revert message\n        // from the contract call.\n        // solium-disable-next-line security/no-low-level-calls\n        (bool success, bytes memory returnData) =\n            address(vendingMachine).call(_extraData);\n\n        string memory revertMessage;\n        assembly {\n            // A revert message is ABI-encoded as a call to Error(string).\n            // Slicing the Error() signature (4 bytes) and Data offset (4 bytes)\n            // leaves us with a pre-encoded string.\n            // We also slice off the ABI-coded length of returnData (32).\n            revertMessage := add(returnData, 0x44)\n        }\n\n        require(success, revertMessage);\n    }\n}\n",
  "sourcePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/scripts/RedemptionScript.sol",
  "ast": {
    "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/scripts/RedemptionScript.sol",
    "exportedSymbols": {
      "RedemptionScript": [
        6197
      ]
    },
    "id": 6198,
    "nodeType": "SourceUnit",
    "nodes": [
      {
        "id": 6069,
        "literals": [
          "solidity",
          "0.5",
          ".17"
        ],
        "nodeType": "PragmaDirective",
        "src": "0:23:17"
      },
      {
        "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/interfaces/ITokenRecipient.sol",
        "file": "../interfaces/ITokenRecipient.sol",
        "id": 6071,
        "nodeType": "ImportDirective",
        "scope": 6198,
        "sourceUnit": 5526,
        "src": "25:66:17",
        "symbolAliases": [
          {
            "foreign": 6070,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/system/TBTCDepositToken.sol",
        "file": "../system/TBTCDepositToken.sol",
        "id": 6073,
        "nodeType": "ImportDirective",
        "scope": 6198,
        "sourceUnit": 6845,
        "src": "92:64:17",
        "symbolAliases": [
          {
            "foreign": 6072,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/system/TBTCToken.sol",
        "file": "../system/TBTCToken.sol",
        "id": 6075,
        "nodeType": "ImportDirective",
        "scope": 6198,
        "sourceUnit": 8562,
        "src": "157:50:17",
        "symbolAliases": [
          {
            "foreign": 6074,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/system/FeeRebateToken.sol",
        "file": "../system/FeeRebateToken.sol",
        "id": 6077,
        "nodeType": "ImportDirective",
        "scope": 6198,
        "sourceUnit": 6301,
        "src": "208:60:17",
        "symbolAliases": [
          {
            "foreign": 6076,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/system/VendingMachine.sol",
        "file": "../system/VendingMachine.sol",
        "id": 6079,
        "nodeType": "ImportDirective",
        "scope": 6198,
        "sourceUnit": 9124,
        "src": "269:60:17",
        "symbolAliases": [
          {
            "foreign": 6078,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/deposit/Deposit.sol",
        "file": "../deposit/Deposit.sol",
        "id": 6081,
        "nodeType": "ImportDirective",
        "scope": 6198,
        "sourceUnit": 1135,
        "src": "330:47:17",
        "symbolAliases": [
          {
            "foreign": 6080,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "absolutePath": "@summa-tx/bitcoin-spv-sol/contracts/BytesLib.sol",
        "file": "@summa-tx/bitcoin-spv-sol/contracts/BytesLib.sol",
        "id": 6083,
        "nodeType": "ImportDirective",
        "scope": 6198,
        "sourceUnit": 13433,
        "src": "378:74:17",
        "symbolAliases": [
          {
            "foreign": 6082,
            "local": null
          }
        ],
        "unitAlias": ""
      },
      {
        "baseContracts": [
          {
            "arguments": null,
            "baseName": {
              "contractScope": null,
              "id": 6084,
              "name": "ITokenRecipient",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 5525,
              "src": "789:15:17",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_ITokenRecipient_$5525",
                "typeString": "contract ITokenRecipient"
              }
            },
            "id": 6085,
            "nodeType": "InheritanceSpecifier",
            "src": "789:15:17"
          }
        ],
        "contractDependencies": [
          5525
        ],
        "contractKind": "contract",
        "documentation": "@notice A one-click script for redeeming TBTC into BTC.\n @dev Wrapper script for VendingMachine.tbtcToBtc\n This contract implements receiveApproval() and can therefore use\n approveAndCall(). This pattern combines TBTC Token approval and\n vendingMachine.tbtcToBtc() in a single transaction.",
        "fullyImplemented": true,
        "id": 6197,
        "linearizedBaseContracts": [
          6197,
          5525
        ],
        "name": "RedemptionScript",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "id": 6088,
            "libraryName": {
              "contractScope": null,
              "id": 6086,
              "name": "BytesLib",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 13432,
              "src": "817:8:17",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_BytesLib_$13432",
                "typeString": "library BytesLib"
              }
            },
            "nodeType": "UsingForDirective",
            "src": "811:25:17",
            "typeName": {
              "id": 6087,
              "name": "bytes",
              "nodeType": "ElementaryTypeName",
              "src": "830:5:17",
              "typeDescriptions": {
                "typeIdentifier": "t_bytes_storage_ptr",
                "typeString": "bytes"
              }
            }
          },
          {
            "constant": false,
            "id": 6090,
            "name": "tbtcToken",
            "nodeType": "VariableDeclaration",
            "scope": 6197,
            "src": "842:19:17",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_contract$_TBTCToken_$8561",
              "typeString": "contract TBTCToken"
            },
            "typeName": {
              "contractScope": null,
              "id": 6089,
              "name": "TBTCToken",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 8561,
              "src": "842:9:17",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_TBTCToken_$8561",
                "typeString": "contract TBTCToken"
              }
            },
            "value": null,
            "visibility": "internal"
          },
          {
            "constant": false,
            "id": 6092,
            "name": "vendingMachine",
            "nodeType": "VariableDeclaration",
            "scope": 6197,
            "src": "867:29:17",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_contract$_VendingMachine_$9123",
              "typeString": "contract VendingMachine"
            },
            "typeName": {
              "contractScope": null,
              "id": 6091,
              "name": "VendingMachine",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 9123,
              "src": "867:14:17",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_VendingMachine_$9123",
                "typeString": "contract VendingMachine"
              }
            },
            "value": null,
            "visibility": "internal"
          },
          {
            "constant": false,
            "id": 6094,
            "name": "feeRebateToken",
            "nodeType": "VariableDeclaration",
            "scope": 6197,
            "src": "902:29:17",
            "stateVariable": true,
            "storageLocation": "default",
            "typeDescriptions": {
              "typeIdentifier": "t_contract$_FeeRebateToken_$6300",
              "typeString": "contract FeeRebateToken"
            },
            "typeName": {
              "contractScope": null,
              "id": 6093,
              "name": "FeeRebateToken",
              "nodeType": "UserDefinedTypeName",
              "referencedDeclaration": 6300,
              "src": "902:14:17",
              "typeDescriptions": {
                "typeIdentifier": "t_contract$_FeeRebateToken_$6300",
                "typeString": "contract FeeRebateToken"
              }
            },
            "value": null,
            "visibility": "internal"
          },
          {
            "body": {
              "id": 6121,
              "nodeType": "Block",
              "src": "1057:166:17",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 6107,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 6103,
                      "name": "vendingMachine",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 6092,
                      "src": "1067:14:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_VendingMachine_$9123",
                        "typeString": "contract VendingMachine"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 6105,
                          "name": "_VendingMachine",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 6096,
                          "src": "1099:15:17",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        ],
                        "id": 6104,
                        "name": "VendingMachine",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 9123,
                        "src": "1084:14:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_contract$_VendingMachine_$9123_$",
                          "typeString": "type(contract VendingMachine)"
                        }
                      },
                      "id": 6106,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "1084:31:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_VendingMachine_$9123",
                        "typeString": "contract VendingMachine"
                      }
                    },
                    "src": "1067:48:17",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_VendingMachine_$9123",
                      "typeString": "contract VendingMachine"
                    }
                  },
                  "id": 6108,
                  "nodeType": "ExpressionStatement",
                  "src": "1067:48:17"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 6113,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 6109,
                      "name": "tbtcToken",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 6090,
                      "src": "1125:9:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_TBTCToken_$8561",
                        "typeString": "contract TBTCToken"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 6111,
                          "name": "_TBTCToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 6098,
                          "src": "1147:10:17",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        ],
                        "id": 6110,
                        "name": "TBTCToken",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 8561,
                        "src": "1137:9:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_contract$_TBTCToken_$8561_$",
                          "typeString": "type(contract TBTCToken)"
                        }
                      },
                      "id": 6112,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "1137:21:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_TBTCToken_$8561",
                        "typeString": "contract TBTCToken"
                      }
                    },
                    "src": "1125:33:17",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_TBTCToken_$8561",
                      "typeString": "contract TBTCToken"
                    }
                  },
                  "id": 6114,
                  "nodeType": "ExpressionStatement",
                  "src": "1125:33:17"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "id": 6119,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftHandSide": {
                      "argumentTypes": null,
                      "id": 6115,
                      "name": "feeRebateToken",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 6094,
                      "src": "1168:14:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_FeeRebateToken_$6300",
                        "typeString": "contract FeeRebateToken"
                      }
                    },
                    "nodeType": "Assignment",
                    "operator": "=",
                    "rightHandSide": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "id": 6117,
                          "name": "_FeeRebateToken",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 6100,
                          "src": "1200:15:17",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        ],
                        "id": 6116,
                        "name": "FeeRebateToken",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 6300,
                        "src": "1185:14:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_contract$_FeeRebateToken_$6300_$",
                          "typeString": "type(contract FeeRebateToken)"
                        }
                      },
                      "id": 6118,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "1185:31:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_contract$_FeeRebateToken_$6300",
                        "typeString": "contract FeeRebateToken"
                      }
                    },
                    "src": "1168:48:17",
                    "typeDescriptions": {
                      "typeIdentifier": "t_contract$_FeeRebateToken_$6300",
                      "typeString": "contract FeeRebateToken"
                    }
                  },
                  "id": 6120,
                  "nodeType": "ExpressionStatement",
                  "src": "1168:48:17"
                }
              ]
            },
            "documentation": null,
            "id": 6122,
            "implemented": true,
            "kind": "constructor",
            "modifiers": [],
            "name": "",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 6101,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 6096,
                  "name": "_VendingMachine",
                  "nodeType": "VariableDeclaration",
                  "scope": 6122,
                  "src": "959:23:17",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 6095,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "959:7:17",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 6098,
                  "name": "_TBTCToken",
                  "nodeType": "VariableDeclaration",
                  "scope": 6122,
                  "src": "992:18:17",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 6097,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "992:7:17",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 6100,
                  "name": "_FeeRebateToken",
                  "nodeType": "VariableDeclaration",
                  "scope": 6122,
                  "src": "1020:23:17",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 6099,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "1020:7:17",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "949:100:17"
            },
            "returnParameters": {
              "id": 6102,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "1057:0:17"
            },
            "scope": 6197,
            "src": "938:285:17",
            "stateMutability": "nonpayable",
            "superFunction": null,
            "visibility": "public"
          },
          {
            "body": {
              "id": 6195,
              "nodeType": "Block",
              "src": "1749:1411:17",
              "statements": [
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        "id": 6139,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "id": 6134,
                            "name": "msg",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 18360,
                            "src": "1837:3:17",
                            "typeDescriptions": {
                              "typeIdentifier": "t_magic_message",
                              "typeString": "msg"
                            }
                          },
                          "id": 6135,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "sender",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "1837:10:17",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address_payable",
                            "typeString": "address payable"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "==",
                        "rightExpression": {
                          "argumentTypes": null,
                          "arguments": [
                            {
                              "argumentTypes": null,
                              "id": 6137,
                              "name": "tbtcToken",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 6090,
                              "src": "1859:9:17",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_TBTCToken_$8561",
                                "typeString": "contract TBTCToken"
                              }
                            }
                          ],
                          "expression": {
                            "argumentTypes": [
                              {
                                "typeIdentifier": "t_contract$_TBTCToken_$8561",
                                "typeString": "contract TBTCToken"
                              }
                            ],
                            "id": 6136,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": true,
                            "lValueRequested": false,
                            "nodeType": "ElementaryTypeNameExpression",
                            "src": "1851:7:17",
                            "typeDescriptions": {
                              "typeIdentifier": "t_type$_t_address_$",
                              "typeString": "type(address)"
                            },
                            "typeName": "address"
                          },
                          "id": 6138,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "kind": "typeConversion",
                          "lValueRequested": false,
                          "names": [],
                          "nodeType": "FunctionCall",
                          "src": "1851:18:17",
                          "typeDescriptions": {
                            "typeIdentifier": "t_address",
                            "typeString": "address"
                          }
                        },
                        "src": "1837:32:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "4f6e6c7920746f6b656e20636f6e74726163742063616e2063616c6c2072656365697665417070726f76616c",
                        "id": 6140,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "1883:46:17",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_5ad58abfd7682657d2caeadc3413ef383abfb8158a9ea3126c46a6e085548c17",
                          "typeString": "literal_string \"Only token contract can call receiveApproval\""
                        },
                        "value": "Only token contract can call receiveApproval"
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_5ad58abfd7682657d2caeadc3413ef383abfb8158a9ea3126c46a6e085548c17",
                          "typeString": "literal_string \"Only token contract can call receiveApproval\""
                        }
                      ],
                      "id": 6133,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        18363,
                        18364
                      ],
                      "referencedDeclaration": 18364,
                      "src": "1816:7:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 6141,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "1816:123:17",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 6142,
                  "nodeType": "ExpressionStatement",
                  "src": "1816:123:17"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 6146,
                        "name": "_from",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 6124,
                        "src": "1973:5:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 6148,
                            "name": "this",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 18482,
                            "src": "1988:4:17",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_RedemptionScript_$6197",
                              "typeString": "contract RedemptionScript"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_contract$_RedemptionScript_$6197",
                              "typeString": "contract RedemptionScript"
                            }
                          ],
                          "id": 6147,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "1980:7:17",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_address_$",
                            "typeString": "type(address)"
                          },
                          "typeName": "address"
                        },
                        "id": 6149,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "1980:13:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 6150,
                        "name": "_amount",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 6126,
                        "src": "1995:7:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 6143,
                        "name": "tbtcToken",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 6090,
                        "src": "1950:9:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_TBTCToken_$8561",
                          "typeString": "contract TBTCToken"
                        }
                      },
                      "id": 6145,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "transferFrom",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 17096,
                      "src": "1950:22:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$",
                        "typeString": "function (address,address,uint256) external returns (bool)"
                      }
                    },
                    "id": 6151,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "1950:53:17",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "id": 6152,
                  "nodeType": "ExpressionStatement",
                  "src": "1950:53:17"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 6157,
                            "name": "vendingMachine",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 6092,
                            "src": "2039:14:17",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_VendingMachine_$9123",
                              "typeString": "contract VendingMachine"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_contract$_VendingMachine_$9123",
                              "typeString": "contract VendingMachine"
                            }
                          ],
                          "id": 6156,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "2031:7:17",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_address_$",
                            "typeString": "type(address)"
                          },
                          "typeName": "address"
                        },
                        "id": 6158,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "2031:23:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 6159,
                        "name": "_amount",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 6126,
                        "src": "2056:7:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        },
                        {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "id": 6153,
                        "name": "tbtcToken",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 6090,
                        "src": "2013:9:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_contract$_TBTCToken_$8561",
                          "typeString": "contract TBTCToken"
                        }
                      },
                      "id": 6155,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "approve",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": 17061,
                      "src": "2013:17:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
                        "typeString": "function (address,uint256) external returns (bool)"
                      }
                    },
                    "id": 6160,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "2013:51:17",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "id": 6161,
                  "nodeType": "ExpressionStatement",
                  "src": "2013:51:17"
                },
                {
                  "assignments": [
                    6163
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 6163,
                      "name": "functionSignature",
                      "nodeType": "VariableDeclaration",
                      "scope": 6195,
                      "src": "2128:24:17",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_bytes4",
                        "typeString": "bytes4"
                      },
                      "typeName": {
                        "id": 6162,
                        "name": "bytes4",
                        "nodeType": "ElementaryTypeName",
                        "src": "2128:6:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bytes4",
                          "typeString": "bytes4"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 6164,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "2128:24:17"
                },
                {
                  "externalReferences": [
                    {
                      "functionSignature": {
                        "declaration": 6163,
                        "isOffset": false,
                        "isSlot": false,
                        "src": "2185:17:17",
                        "valueSize": 1
                      }
                    },
                    {
                      "_extraData": {
                        "declaration": 6130,
                        "isOffset": false,
                        "isSlot": false,
                        "src": "2220:10:17",
                        "valueSize": 1
                      }
                    }
                  ],
                  "id": 6165,
                  "nodeType": "InlineAssembly",
                  "operations": "{\n    functionSignature := and(mload(add(_extraData, 0x20)), not(0xff))\n}",
                  "src": "2162:98:17"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "commonType": {
                          "typeIdentifier": "t_bytes4",
                          "typeString": "bytes4"
                        },
                        "id": 6171,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "lValueRequested": false,
                        "leftExpression": {
                          "argumentTypes": null,
                          "id": 6167,
                          "name": "functionSignature",
                          "nodeType": "Identifier",
                          "overloadedDeclarations": [],
                          "referencedDeclaration": 6163,
                          "src": "2290:17:17",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bytes4",
                            "typeString": "bytes4"
                          }
                        },
                        "nodeType": "BinaryOperation",
                        "operator": "==",
                        "rightExpression": {
                          "argumentTypes": null,
                          "expression": {
                            "argumentTypes": null,
                            "expression": {
                              "argumentTypes": null,
                              "id": 6168,
                              "name": "vendingMachine",
                              "nodeType": "Identifier",
                              "overloadedDeclarations": [],
                              "referencedDeclaration": 6092,
                              "src": "2311:14:17",
                              "typeDescriptions": {
                                "typeIdentifier": "t_contract$_VendingMachine_$9123",
                                "typeString": "contract VendingMachine"
                              }
                            },
                            "id": 6169,
                            "isConstant": false,
                            "isLValue": false,
                            "isPure": false,
                            "lValueRequested": false,
                            "memberName": "tbtcToBtc",
                            "nodeType": "MemberAccess",
                            "referencedDeclaration": 9122,
                            "src": "2311:24:17",
                            "typeDescriptions": {
                              "typeIdentifier": "t_function_external_nonpayable$_t_address_payable_$_t_bytes8_$_t_bytes_memory_ptr_$returns$__$",
                              "typeString": "function (address payable,bytes8,bytes memory) external"
                            }
                          },
                          "id": 6170,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "memberName": "selector",
                          "nodeType": "MemberAccess",
                          "referencedDeclaration": null,
                          "src": "2311:33:17",
                          "typeDescriptions": {
                            "typeIdentifier": "t_bytes4",
                            "typeString": "bytes4"
                          }
                        },
                        "src": "2290:54:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "hexValue": "426164205f657874726144617461207369676e61747572652e2043616c6c206d75737420626520746f2074627463546f4274632e",
                        "id": 6172,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "kind": "string",
                        "lValueRequested": false,
                        "nodeType": "Literal",
                        "src": "2358:54:17",
                        "subdenomination": null,
                        "typeDescriptions": {
                          "typeIdentifier": "t_stringliteral_883463e9264686ff6579152095fa8091087bec17866dd00fe5d0be20efb0af5b",
                          "typeString": "literal_string \"Bad _extraData signature. Call must be to tbtcToBtc.\""
                        },
                        "value": "Bad _extraData signature. Call must be to tbtcToBtc."
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_stringliteral_883463e9264686ff6579152095fa8091087bec17866dd00fe5d0be20efb0af5b",
                          "typeString": "literal_string \"Bad _extraData signature. Call must be to tbtcToBtc.\""
                        }
                      ],
                      "id": 6166,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        18363,
                        18364
                      ],
                      "referencedDeclaration": 18364,
                      "src": "2269:7:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 6173,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "2269:153:17",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 6174,
                  "nodeType": "ExpressionStatement",
                  "src": "2269:153:17"
                },
                {
                  "assignments": [
                    6176,
                    6178
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 6176,
                      "name": "success",
                      "nodeType": "VariableDeclaration",
                      "scope": 6195,
                      "src": "2618:12:17",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_bool",
                        "typeString": "bool"
                      },
                      "typeName": {
                        "id": 6175,
                        "name": "bool",
                        "nodeType": "ElementaryTypeName",
                        "src": "2618:4:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    },
                    {
                      "constant": false,
                      "id": 6178,
                      "name": "returnData",
                      "nodeType": "VariableDeclaration",
                      "scope": 6195,
                      "src": "2632:23:17",
                      "stateVariable": false,
                      "storageLocation": "memory",
                      "typeDescriptions": {
                        "typeIdentifier": "t_bytes_memory_ptr",
                        "typeString": "bytes"
                      },
                      "typeName": {
                        "id": 6177,
                        "name": "bytes",
                        "nodeType": "ElementaryTypeName",
                        "src": "2632:5:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bytes_storage_ptr",
                          "typeString": "bytes"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 6185,
                  "initialValue": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 6183,
                        "name": "_extraData",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 6130,
                        "src": "2700:10:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bytes_memory_ptr",
                          "typeString": "bytes memory"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bytes_memory_ptr",
                          "typeString": "bytes memory"
                        }
                      ],
                      "expression": {
                        "argumentTypes": null,
                        "arguments": [
                          {
                            "argumentTypes": null,
                            "id": 6180,
                            "name": "vendingMachine",
                            "nodeType": "Identifier",
                            "overloadedDeclarations": [],
                            "referencedDeclaration": 6092,
                            "src": "2679:14:17",
                            "typeDescriptions": {
                              "typeIdentifier": "t_contract$_VendingMachine_$9123",
                              "typeString": "contract VendingMachine"
                            }
                          }
                        ],
                        "expression": {
                          "argumentTypes": [
                            {
                              "typeIdentifier": "t_contract$_VendingMachine_$9123",
                              "typeString": "contract VendingMachine"
                            }
                          ],
                          "id": 6179,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "lValueRequested": false,
                          "nodeType": "ElementaryTypeNameExpression",
                          "src": "2671:7:17",
                          "typeDescriptions": {
                            "typeIdentifier": "t_type$_t_address_$",
                            "typeString": "type(address)"
                          },
                          "typeName": "address"
                        },
                        "id": 6181,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": false,
                        "kind": "typeConversion",
                        "lValueRequested": false,
                        "names": [],
                        "nodeType": "FunctionCall",
                        "src": "2671:23:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_address",
                          "typeString": "address"
                        }
                      },
                      "id": 6182,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": false,
                      "lValueRequested": false,
                      "memberName": "call",
                      "nodeType": "MemberAccess",
                      "referencedDeclaration": null,
                      "src": "2671:28:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_barecall_payable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$",
                        "typeString": "function (bytes memory) payable returns (bool,bytes memory)"
                      }
                    },
                    "id": 6184,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "2671:40:17",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
                      "typeString": "tuple(bool,bytes memory)"
                    }
                  },
                  "nodeType": "VariableDeclarationStatement",
                  "src": "2617:94:17"
                },
                {
                  "assignments": [
                    6187
                  ],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 6187,
                      "name": "revertMessage",
                      "nodeType": "VariableDeclaration",
                      "scope": 6195,
                      "src": "2722:27:17",
                      "stateVariable": false,
                      "storageLocation": "memory",
                      "typeDescriptions": {
                        "typeIdentifier": "t_string_memory_ptr",
                        "typeString": "string"
                      },
                      "typeName": {
                        "id": 6186,
                        "name": "string",
                        "nodeType": "ElementaryTypeName",
                        "src": "2722:6:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_string_storage_ptr",
                          "typeString": "string"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 6188,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "2722:27:17"
                },
                {
                  "externalReferences": [
                    {
                      "revertMessage": {
                        "declaration": 6187,
                        "isOffset": false,
                        "isSlot": false,
                        "src": "3064:13:17",
                        "valueSize": 1
                      }
                    },
                    {
                      "returnData": {
                        "declaration": 6178,
                        "isOffset": false,
                        "isSlot": false,
                        "src": "3085:10:17",
                        "valueSize": 1
                      }
                    }
                  ],
                  "id": 6189,
                  "nodeType": "InlineAssembly",
                  "operations": "{\n    revertMessage := add(returnData, 0x44)\n}",
                  "src": "2759:353:17"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "arguments": [
                      {
                        "argumentTypes": null,
                        "id": 6191,
                        "name": "success",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 6176,
                        "src": "3130:7:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        }
                      },
                      {
                        "argumentTypes": null,
                        "id": 6192,
                        "name": "revertMessage",
                        "nodeType": "Identifier",
                        "overloadedDeclarations": [],
                        "referencedDeclaration": 6187,
                        "src": "3139:13:17",
                        "typeDescriptions": {
                          "typeIdentifier": "t_string_memory_ptr",
                          "typeString": "string memory"
                        }
                      }
                    ],
                    "expression": {
                      "argumentTypes": [
                        {
                          "typeIdentifier": "t_bool",
                          "typeString": "bool"
                        },
                        {
                          "typeIdentifier": "t_string_memory_ptr",
                          "typeString": "string memory"
                        }
                      ],
                      "id": 6190,
                      "name": "require",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [
                        18363,
                        18364
                      ],
                      "referencedDeclaration": 18364,
                      "src": "3122:7:17",
                      "typeDescriptions": {
                        "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
                        "typeString": "function (bool,string memory) pure"
                      }
                    },
                    "id": 6193,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "kind": "functionCall",
                    "lValueRequested": false,
                    "names": [],
                    "nodeType": "FunctionCall",
                    "src": "3122:31:17",
                    "typeDescriptions": {
                      "typeIdentifier": "t_tuple$__$",
                      "typeString": "tuple()"
                    }
                  },
                  "id": 6194,
                  "nodeType": "ExpressionStatement",
                  "src": "3122:31:17"
                }
              ]
            },
            "documentation": "@notice Receives approval for a TBTC transfer, and calls `VendingMachine.tbtcToBtc` for a user.\n @dev Implements the approveAndCall receiver interface.\n @param _from The owner of the token who approved them for transfer.\n @param _amount Approved TBTC amount for the transfer.\n @param _extraData Encoded function call to `VendingMachine.tbtcToBtc`.",
            "id": 6196,
            "implemented": true,
            "kind": "function",
            "modifiers": [],
            "name": "receiveApproval",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 6131,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 6124,
                  "name": "_from",
                  "nodeType": "VariableDeclaration",
                  "scope": 6196,
                  "src": "1647:13:17",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 6123,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "1647:7:17",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 6126,
                  "name": "_amount",
                  "nodeType": "VariableDeclaration",
                  "scope": 6196,
                  "src": "1670:15:17",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_uint256",
                    "typeString": "uint256"
                  },
                  "typeName": {
                    "id": 6125,
                    "name": "uint256",
                    "nodeType": "ElementaryTypeName",
                    "src": "1670:7:17",
                    "typeDescriptions": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 6128,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 6196,
                  "src": "1695:7:17",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 6127,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "1695:7:17",
                    "stateMutability": "nonpayable",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                },
                {
                  "constant": false,
                  "id": 6130,
                  "name": "_extraData",
                  "nodeType": "VariableDeclaration",
                  "scope": 6196,
                  "src": "1712:23:17",
                  "stateVariable": false,
                  "storageLocation": "memory",
                  "typeDescriptions": {
                    "typeIdentifier": "t_bytes_memory_ptr",
                    "typeString": "bytes"
                  },
                  "typeName": {
                    "id": 6129,
                    "name": "bytes",
                    "nodeType": "ElementaryTypeName",
                    "src": "1712:5:17",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bytes_storage_ptr",
                      "typeString": "bytes"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "1637:104:17"
            },
            "returnParameters": {
              "id": 6132,
              "nodeType": "ParameterList",
              "parameters": [],
              "src": "1749:0:17"
            },
            "scope": 6197,
            "src": "1613:1547:17",
            "stateMutability": "nonpayable",
            "superFunction": 5524,
            "visibility": "public"
          }
        ],
        "scope": 6198,
        "src": "760:2402:17"
      }
    ],
    "src": "0:3163:17"
  },
  "legacyAST": {
    "attributes": {
      "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/scripts/RedemptionScript.sol",
      "exportedSymbols": {
        "RedemptionScript": [
          6197
        ]
      }
    },
    "children": [
      {
        "attributes": {
          "literals": [
            "solidity",
            "0.5",
            ".17"
          ]
        },
        "id": 6069,
        "name": "PragmaDirective",
        "src": "0:23:17"
      },
      {
        "attributes": {
          "SourceUnit": 5526,
          "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/interfaces/ITokenRecipient.sol",
          "file": "../interfaces/ITokenRecipient.sol",
          "scope": 6198,
          "symbolAliases": [
            {
              "foreign": 6070,
              "local": null
            }
          ],
          "unitAlias": ""
        },
        "id": 6071,
        "name": "ImportDirective",
        "src": "25:66:17"
      },
      {
        "attributes": {
          "SourceUnit": 6845,
          "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/system/TBTCDepositToken.sol",
          "file": "../system/TBTCDepositToken.sol",
          "scope": 6198,
          "symbolAliases": [
            {
              "foreign": 6072,
              "local": null
            }
          ],
          "unitAlias": ""
        },
        "id": 6073,
        "name": "ImportDirective",
        "src": "92:64:17"
      },
      {
        "attributes": {
          "SourceUnit": 8562,
          "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/system/TBTCToken.sol",
          "file": "../system/TBTCToken.sol",
          "scope": 6198,
          "symbolAliases": [
            {
              "foreign": 6074,
              "local": null
            }
          ],
          "unitAlias": ""
        },
        "id": 6075,
        "name": "ImportDirective",
        "src": "157:50:17"
      },
      {
        "attributes": {
          "SourceUnit": 6301,
          "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/system/FeeRebateToken.sol",
          "file": "../system/FeeRebateToken.sol",
          "scope": 6198,
          "symbolAliases": [
            {
              "foreign": 6076,
              "local": null
            }
          ],
          "unitAlias": ""
        },
        "id": 6077,
        "name": "ImportDirective",
        "src": "208:60:17"
      },
      {
        "attributes": {
          "SourceUnit": 9124,
          "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/system/VendingMachine.sol",
          "file": "../system/VendingMachine.sol",
          "scope": 6198,
          "symbolAliases": [
            {
              "foreign": 6078,
              "local": null
            }
          ],
          "unitAlias": ""
        },
        "id": 6079,
        "name": "ImportDirective",
        "src": "269:60:17"
      },
      {
        "attributes": {
          "SourceUnit": 1135,
          "absolutePath": "/home/runner/work/tbtc/tbtc/solidity/contracts/deposit/Deposit.sol",
          "file": "../deposit/Deposit.sol",
          "scope": 6198,
          "symbolAliases": [
            {
              "foreign": 6080,
              "local": null
            }
          ],
          "unitAlias": ""
        },
        "id": 6081,
        "name": "ImportDirective",
        "src": "330:47:17"
      },
      {
        "attributes": {
          "SourceUnit": 13433,
          "absolutePath": "@summa-tx/bitcoin-spv-sol/contracts/BytesLib.sol",
          "file": "@summa-tx/bitcoin-spv-sol/contracts/BytesLib.sol",
          "scope": 6198,
          "symbolAliases": [
            {
              "foreign": 6082,
              "local": null
            }
          ],
          "unitAlias": ""
        },
        "id": 6083,
        "name": "ImportDirective",
        "src": "378:74:17"
      },
      {
        "attributes": {
          "contractDependencies": [
            5525
          ],
          "contractKind": "contract",
          "documentation": "@notice A one-click script for redeeming TBTC into BTC.\n @dev Wrapper script for VendingMachine.tbtcToBtc\n This contract implements receiveApproval() and can therefore use\n approveAndCall(). This pattern combines TBTC Token approval and\n vendingMachine.tbtcToBtc() in a single transaction.",
          "fullyImplemented": true,
          "linearizedBaseContracts": [
            6197,
            5525
          ],
          "name": "RedemptionScript",
          "scope": 6198
        },
        "children": [
          {
            "attributes": {
              "arguments": null
            },
            "children": [
              {
                "attributes": {
                  "contractScope": null,
                  "name": "ITokenRecipient",
                  "referencedDeclaration": 5525,
                  "type": "contract ITokenRecipient"
                },
                "id": 6084,
                "name": "UserDefinedTypeName",
                "src": "789:15:17"
              }
            ],
            "id": 6085,
            "name": "InheritanceSpecifier",
            "src": "789:15:17"
          },
          {
            "children": [
              {
                "attributes": {
                  "contractScope": null,
                  "name": "BytesLib",
                  "referencedDeclaration": 13432,
                  "type": "library BytesLib"
                },
                "id": 6086,
                "name": "UserDefinedTypeName",
                "src": "817:8:17"
              },
              {
                "attributes": {
                  "name": "bytes",
                  "type": "bytes"
                },
                "id": 6087,
                "name": "ElementaryTypeName",
                "src": "830:5:17"
              }
            ],
            "id": 6088,
            "name": "UsingForDirective",
            "src": "811:25:17"
          },
          {
            "attributes": {
              "constant": false,
              "name": "tbtcToken",
              "scope": 6197,
              "stateVariable": true,
              "storageLocation": "default",
              "type": "contract TBTCToken",
              "value": null,
              "visibility": "internal"
            },
            "children": [
              {
                "attributes": {
                  "contractScope": null,
                  "name": "TBTCToken",
                  "referencedDeclaration": 8561,
                  "type": "contract TBTCToken"
                },
                "id": 6089,
                "name": "UserDefinedTypeName",
                "src": "842:9:17"
              }
            ],
            "id": 6090,
            "name": "VariableDeclaration",
            "src": "842:19:17"
          },
          {
            "attributes": {
              "constant": false,
              "name": "vendingMachine",
              "scope": 6197,
              "stateVariable": true,
              "storageLocation": "default",
              "type": "contract VendingMachine",
              "value": null,
              "visibility": "internal"
            },
            "children": [
              {
                "attributes": {
                  "contractScope": null,
                  "name": "VendingMachine",
                  "referencedDeclaration": 9123,
                  "type": "contract VendingMachine"
                },
                "id": 6091,
                "name": "UserDefinedTypeName",
                "src": "867:14:17"
              }
            ],
            "id": 6092,
            "name": "VariableDeclaration",
            "src": "867:29:17"
          },
          {
            "attributes": {
              "constant": false,
              "name": "feeRebateToken",
              "scope": 6197,
              "stateVariable": true,
              "storageLocation": "default",
              "type": "contract FeeRebateToken",
              "value": null,
              "visibility": "internal"
            },
            "children": [
              {
                "attributes": {
                  "contractScope": null,
                  "name": "FeeRebateToken",
                  "referencedDeclaration": 6300,
                  "type": "contract FeeRebateToken"
                },
                "id": 6093,
                "name": "UserDefinedTypeName",
                "src": "902:14:17"
              }
            ],
            "id": 6094,
            "name": "VariableDeclaration",
            "src": "902:29:17"
          },
          {
            "attributes": {
              "documentation": null,
              "implemented": true,
              "isConstructor": true,
              "kind": "constructor",
              "modifiers": [
                null
              ],
              "name": "",
              "scope": 6197,
              "stateMutability": "nonpayable",
              "superFunction": null,
              "visibility": "public"
            },
            "children": [
              {
                "children": [
                  {
                    "attributes": {
                      "constant": false,
                      "name": "_VendingMachine",
                      "scope": 6122,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "address",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "address",
                          "stateMutability": "nonpayable",
                          "type": "address"
                        },
                        "id": 6095,
                        "name": "ElementaryTypeName",
                        "src": "959:7:17"
                      }
                    ],
                    "id": 6096,
                    "name": "VariableDeclaration",
                    "src": "959:23:17"
                  },
                  {
                    "attributes": {
                      "constant": false,
                      "name": "_TBTCToken",
                      "scope": 6122,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "address",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "address",
                          "stateMutability": "nonpayable",
                          "type": "address"
                        },
                        "id": 6097,
                        "name": "ElementaryTypeName",
                        "src": "992:7:17"
                      }
                    ],
                    "id": 6098,
                    "name": "VariableDeclaration",
                    "src": "992:18:17"
                  },
                  {
                    "attributes": {
                      "constant": false,
                      "name": "_FeeRebateToken",
                      "scope": 6122,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "address",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "address",
                          "stateMutability": "nonpayable",
                          "type": "address"
                        },
                        "id": 6099,
                        "name": "ElementaryTypeName",
                        "src": "1020:7:17"
                      }
                    ],
                    "id": 6100,
                    "name": "VariableDeclaration",
                    "src": "1020:23:17"
                  }
                ],
                "id": 6101,
                "name": "ParameterList",
                "src": "949:100:17"
              },
              {
                "attributes": {
                  "parameters": [
                    null
                  ]
                },
                "children": [],
                "id": 6102,
                "name": "ParameterList",
                "src": "1057:0:17"
              },
              {
                "children": [
                  {
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "operator": "=",
                          "type": "contract VendingMachine"
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 6092,
                              "type": "contract VendingMachine",
                              "value": "vendingMachine"
                            },
                            "id": 6103,
                            "name": "Identifier",
                            "src": "1067:14:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "isStructConstructorCall": false,
                              "lValueRequested": false,
                              "names": [
                                null
                              ],
                              "type": "contract VendingMachine",
                              "type_conversion": true
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": [
                                    {
                                      "typeIdentifier": "t_address",
                                      "typeString": "address"
                                    }
                                  ],
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 9123,
                                  "type": "type(contract VendingMachine)",
                                  "value": "VendingMachine"
                                },
                                "id": 6104,
                                "name": "Identifier",
                                "src": "1084:14:17"
                              },
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 6096,
                                  "type": "address",
                                  "value": "_VendingMachine"
                                },
                                "id": 6105,
                                "name": "Identifier",
                                "src": "1099:15:17"
                              }
                            ],
                            "id": 6106,
                            "name": "FunctionCall",
                            "src": "1084:31:17"
                          }
                        ],
                        "id": 6107,
                        "name": "Assignment",
                        "src": "1067:48:17"
                      }
                    ],
                    "id": 6108,
                    "name": "ExpressionStatement",
                    "src": "1067:48:17"
                  },
                  {
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "operator": "=",
                          "type": "contract TBTCToken"
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 6090,
                              "type": "contract TBTCToken",
                              "value": "tbtcToken"
                            },
                            "id": 6109,
                            "name": "Identifier",
                            "src": "1125:9:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "isStructConstructorCall": false,
                              "lValueRequested": false,
                              "names": [
                                null
                              ],
                              "type": "contract TBTCToken",
                              "type_conversion": true
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": [
                                    {
                                      "typeIdentifier": "t_address",
                                      "typeString": "address"
                                    }
                                  ],
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 8561,
                                  "type": "type(contract TBTCToken)",
                                  "value": "TBTCToken"
                                },
                                "id": 6110,
                                "name": "Identifier",
                                "src": "1137:9:17"
                              },
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 6098,
                                  "type": "address",
                                  "value": "_TBTCToken"
                                },
                                "id": 6111,
                                "name": "Identifier",
                                "src": "1147:10:17"
                              }
                            ],
                            "id": 6112,
                            "name": "FunctionCall",
                            "src": "1137:21:17"
                          }
                        ],
                        "id": 6113,
                        "name": "Assignment",
                        "src": "1125:33:17"
                      }
                    ],
                    "id": 6114,
                    "name": "ExpressionStatement",
                    "src": "1125:33:17"
                  },
                  {
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "lValueRequested": false,
                          "operator": "=",
                          "type": "contract FeeRebateToken"
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 6094,
                              "type": "contract FeeRebateToken",
                              "value": "feeRebateToken"
                            },
                            "id": 6115,
                            "name": "Identifier",
                            "src": "1168:14:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "isStructConstructorCall": false,
                              "lValueRequested": false,
                              "names": [
                                null
                              ],
                              "type": "contract FeeRebateToken",
                              "type_conversion": true
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": [
                                    {
                                      "typeIdentifier": "t_address",
                                      "typeString": "address"
                                    }
                                  ],
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 6300,
                                  "type": "type(contract FeeRebateToken)",
                                  "value": "FeeRebateToken"
                                },
                                "id": 6116,
                                "name": "Identifier",
                                "src": "1185:14:17"
                              },
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 6100,
                                  "type": "address",
                                  "value": "_FeeRebateToken"
                                },
                                "id": 6117,
                                "name": "Identifier",
                                "src": "1200:15:17"
                              }
                            ],
                            "id": 6118,
                            "name": "FunctionCall",
                            "src": "1185:31:17"
                          }
                        ],
                        "id": 6119,
                        "name": "Assignment",
                        "src": "1168:48:17"
                      }
                    ],
                    "id": 6120,
                    "name": "ExpressionStatement",
                    "src": "1168:48:17"
                  }
                ],
                "id": 6121,
                "name": "Block",
                "src": "1057:166:17"
              }
            ],
            "id": 6122,
            "name": "FunctionDefinition",
            "src": "938:285:17"
          },
          {
            "attributes": {
              "documentation": "@notice Receives approval for a TBTC transfer, and calls `VendingMachine.tbtcToBtc` for a user.\n @dev Implements the approveAndCall receiver interface.\n @param _from The owner of the token who approved them for transfer.\n @param _amount Approved TBTC amount for the transfer.\n @param _extraData Encoded function call to `VendingMachine.tbtcToBtc`.",
              "implemented": true,
              "isConstructor": false,
              "kind": "function",
              "modifiers": [
                null
              ],
              "name": "receiveApproval",
              "scope": 6197,
              "stateMutability": "nonpayable",
              "superFunction": 5524,
              "visibility": "public"
            },
            "children": [
              {
                "children": [
                  {
                    "attributes": {
                      "constant": false,
                      "name": "_from",
                      "scope": 6196,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "address",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "address",
                          "stateMutability": "nonpayable",
                          "type": "address"
                        },
                        "id": 6123,
                        "name": "ElementaryTypeName",
                        "src": "1647:7:17"
                      }
                    ],
                    "id": 6124,
                    "name": "VariableDeclaration",
                    "src": "1647:13:17"
                  },
                  {
                    "attributes": {
                      "constant": false,
                      "name": "_amount",
                      "scope": 6196,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "uint256",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "uint256",
                          "type": "uint256"
                        },
                        "id": 6125,
                        "name": "ElementaryTypeName",
                        "src": "1670:7:17"
                      }
                    ],
                    "id": 6126,
                    "name": "VariableDeclaration",
                    "src": "1670:15:17"
                  },
                  {
                    "attributes": {
                      "constant": false,
                      "name": "",
                      "scope": 6196,
                      "stateVariable": false,
                      "storageLocation": "default",
                      "type": "address",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "address",
                          "stateMutability": "nonpayable",
                          "type": "address"
                        },
                        "id": 6127,
                        "name": "ElementaryTypeName",
                        "src": "1695:7:17"
                      }
                    ],
                    "id": 6128,
                    "name": "VariableDeclaration",
                    "src": "1695:7:17"
                  },
                  {
                    "attributes": {
                      "constant": false,
                      "name": "_extraData",
                      "scope": 6196,
                      "stateVariable": false,
                      "storageLocation": "memory",
                      "type": "bytes",
                      "value": null,
                      "visibility": "internal"
                    },
                    "children": [
                      {
                        "attributes": {
                          "name": "bytes",
                          "type": "bytes"
                        },
                        "id": 6129,
                        "name": "ElementaryTypeName",
                        "src": "1712:5:17"
                      }
                    ],
                    "id": 6130,
                    "name": "VariableDeclaration",
                    "src": "1712:23:17"
                  }
                ],
                "id": 6131,
                "name": "ParameterList",
                "src": "1637:104:17"
              },
              {
                "attributes": {
                  "parameters": [
                    null
                  ]
                },
                "children": [],
                "id": 6132,
                "name": "ParameterList",
                "src": "1749:0:17"
              },
              {
                "children": [
                  {
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "isStructConstructorCall": false,
                          "lValueRequested": false,
                          "names": [
                            null
                          ],
                          "type": "tuple()",
                          "type_conversion": false
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": [
                                {
                                  "typeIdentifier": "t_bool",
                                  "typeString": "bool"
                                },
                                {
                                  "typeIdentifier": "t_stringliteral_5ad58abfd7682657d2caeadc3413ef383abfb8158a9ea3126c46a6e085548c17",
                                  "typeString": "literal_string \"Only token contract can call receiveApproval\""
                                }
                              ],
                              "overloadedDeclarations": [
                                18363,
                                18364
                              ],
                              "referencedDeclaration": 18364,
                              "type": "function (bool,string memory) pure",
                              "value": "require"
                            },
                            "id": 6133,
                            "name": "Identifier",
                            "src": "1816:7:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "commonType": {
                                "typeIdentifier": "t_address",
                                "typeString": "address"
                              },
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "operator": "==",
                              "type": "bool"
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "member_name": "sender",
                                  "referencedDeclaration": null,
                                  "type": "address payable"
                                },
                                "children": [
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "overloadedDeclarations": [
                                        null
                                      ],
                                      "referencedDeclaration": 18360,
                                      "type": "msg",
                                      "value": "msg"
                                    },
                                    "id": 6134,
                                    "name": "Identifier",
                                    "src": "1837:3:17"
                                  }
                                ],
                                "id": 6135,
                                "name": "MemberAccess",
                                "src": "1837:10:17"
                              },
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": false,
                                  "isStructConstructorCall": false,
                                  "lValueRequested": false,
                                  "names": [
                                    null
                                  ],
                                  "type": "address",
                                  "type_conversion": true
                                },
                                "children": [
                                  {
                                    "attributes": {
                                      "argumentTypes": [
                                        {
                                          "typeIdentifier": "t_contract$_TBTCToken_$8561",
                                          "typeString": "contract TBTCToken"
                                        }
                                      ],
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "lValueRequested": false,
                                      "type": "type(address)",
                                      "value": "address"
                                    },
                                    "id": 6136,
                                    "name": "ElementaryTypeNameExpression",
                                    "src": "1851:7:17"
                                  },
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "overloadedDeclarations": [
                                        null
                                      ],
                                      "referencedDeclaration": 6090,
                                      "type": "contract TBTCToken",
                                      "value": "tbtcToken"
                                    },
                                    "id": 6137,
                                    "name": "Identifier",
                                    "src": "1859:9:17"
                                  }
                                ],
                                "id": 6138,
                                "name": "FunctionCall",
                                "src": "1851:18:17"
                              }
                            ],
                            "id": 6139,
                            "name": "BinaryOperation",
                            "src": "1837:32:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "hexvalue": "4f6e6c7920746f6b656e20636f6e74726163742063616e2063616c6c2072656365697665417070726f76616c",
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "lValueRequested": false,
                              "subdenomination": null,
                              "token": "string",
                              "type": "literal_string \"Only token contract can call receiveApproval\"",
                              "value": "Only token contract can call receiveApproval"
                            },
                            "id": 6140,
                            "name": "Literal",
                            "src": "1883:46:17"
                          }
                        ],
                        "id": 6141,
                        "name": "FunctionCall",
                        "src": "1816:123:17"
                      }
                    ],
                    "id": 6142,
                    "name": "ExpressionStatement",
                    "src": "1816:123:17"
                  },
                  {
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "isStructConstructorCall": false,
                          "lValueRequested": false,
                          "names": [
                            null
                          ],
                          "type": "bool",
                          "type_conversion": false
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": [
                                {
                                  "typeIdentifier": "t_address",
                                  "typeString": "address"
                                },
                                {
                                  "typeIdentifier": "t_address",
                                  "typeString": "address"
                                },
                                {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              ],
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "member_name": "transferFrom",
                              "referencedDeclaration": 17096,
                              "type": "function (address,address,uint256) external returns (bool)"
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 6090,
                                  "type": "contract TBTCToken",
                                  "value": "tbtcToken"
                                },
                                "id": 6143,
                                "name": "Identifier",
                                "src": "1950:9:17"
                              }
                            ],
                            "id": 6145,
                            "name": "MemberAccess",
                            "src": "1950:22:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 6124,
                              "type": "address",
                              "value": "_from"
                            },
                            "id": 6146,
                            "name": "Identifier",
                            "src": "1973:5:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "isStructConstructorCall": false,
                              "lValueRequested": false,
                              "names": [
                                null
                              ],
                              "type": "address",
                              "type_conversion": true
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": [
                                    {
                                      "typeIdentifier": "t_contract$_RedemptionScript_$6197",
                                      "typeString": "contract RedemptionScript"
                                    }
                                  ],
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": true,
                                  "lValueRequested": false,
                                  "type": "type(address)",
                                  "value": "address"
                                },
                                "id": 6147,
                                "name": "ElementaryTypeNameExpression",
                                "src": "1980:7:17"
                              },
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 18482,
                                  "type": "contract RedemptionScript",
                                  "value": "this"
                                },
                                "id": 6148,
                                "name": "Identifier",
                                "src": "1988:4:17"
                              }
                            ],
                            "id": 6149,
                            "name": "FunctionCall",
                            "src": "1980:13:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 6126,
                              "type": "uint256",
                              "value": "_amount"
                            },
                            "id": 6150,
                            "name": "Identifier",
                            "src": "1995:7:17"
                          }
                        ],
                        "id": 6151,
                        "name": "FunctionCall",
                        "src": "1950:53:17"
                      }
                    ],
                    "id": 6152,
                    "name": "ExpressionStatement",
                    "src": "1950:53:17"
                  },
                  {
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "isStructConstructorCall": false,
                          "lValueRequested": false,
                          "names": [
                            null
                          ],
                          "type": "bool",
                          "type_conversion": false
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": [
                                {
                                  "typeIdentifier": "t_address",
                                  "typeString": "address"
                                },
                                {
                                  "typeIdentifier": "t_uint256",
                                  "typeString": "uint256"
                                }
                              ],
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "member_name": "approve",
                              "referencedDeclaration": 17061,
                              "type": "function (address,uint256) external returns (bool)"
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 6090,
                                  "type": "contract TBTCToken",
                                  "value": "tbtcToken"
                                },
                                "id": 6153,
                                "name": "Identifier",
                                "src": "2013:9:17"
                              }
                            ],
                            "id": 6155,
                            "name": "MemberAccess",
                            "src": "2013:17:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "isStructConstructorCall": false,
                              "lValueRequested": false,
                              "names": [
                                null
                              ],
                              "type": "address",
                              "type_conversion": true
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": [
                                    {
                                      "typeIdentifier": "t_contract$_VendingMachine_$9123",
                                      "typeString": "contract VendingMachine"
                                    }
                                  ],
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": true,
                                  "lValueRequested": false,
                                  "type": "type(address)",
                                  "value": "address"
                                },
                                "id": 6156,
                                "name": "ElementaryTypeNameExpression",
                                "src": "2031:7:17"
                              },
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 6092,
                                  "type": "contract VendingMachine",
                                  "value": "vendingMachine"
                                },
                                "id": 6157,
                                "name": "Identifier",
                                "src": "2039:14:17"
                              }
                            ],
                            "id": 6158,
                            "name": "FunctionCall",
                            "src": "2031:23:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 6126,
                              "type": "uint256",
                              "value": "_amount"
                            },
                            "id": 6159,
                            "name": "Identifier",
                            "src": "2056:7:17"
                          }
                        ],
                        "id": 6160,
                        "name": "FunctionCall",
                        "src": "2013:51:17"
                      }
                    ],
                    "id": 6161,
                    "name": "ExpressionStatement",
                    "src": "2013:51:17"
                  },
                  {
                    "attributes": {
                      "assignments": [
                        6163
                      ],
                      "initialValue": null
                    },
                    "children": [
                      {
                        "attributes": {
                          "constant": false,
                          "name": "functionSignature",
                          "scope": 6195,
                          "stateVariable": false,
                          "storageLocation": "default",
                          "type": "bytes4",
                          "value": null,
                          "visibility": "internal"
                        },
                        "children": [
                          {
                            "attributes": {
                              "name": "bytes4",
                              "type": "bytes4"
                            },
                            "id": 6162,
                            "name": "ElementaryTypeName",
                            "src": "2128:6:17"
                          }
                        ],
                        "id": 6163,
                        "name": "VariableDeclaration",
                        "src": "2128:24:17"
                      }
                    ],
                    "id": 6164,
                    "name": "VariableDeclarationStatement",
                    "src": "2128:24:17"
                  },
                  {
                    "attributes": {
                      "externalReferences": [
                        {
                          "functionSignature": {
                            "declaration": 6163,
                            "isOffset": false,
                            "isSlot": false,
                            "src": "2185:17:17",
                            "valueSize": 1
                          }
                        },
                        {
                          "_extraData": {
                            "declaration": 6130,
                            "isOffset": false,
                            "isSlot": false,
                            "src": "2220:10:17",
                            "valueSize": 1
                          }
                        }
                      ],
                      "operations": "{\n    functionSignature := and(mload(add(_extraData, 0x20)), not(0xff))\n}"
                    },
                    "children": [],
                    "id": 6165,
                    "name": "InlineAssembly",
                    "src": "2162:98:17"
                  },
                  {
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "isStructConstructorCall": false,
                          "lValueRequested": false,
                          "names": [
                            null
                          ],
                          "type": "tuple()",
                          "type_conversion": false
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": [
                                {
                                  "typeIdentifier": "t_bool",
                                  "typeString": "bool"
                                },
                                {
                                  "typeIdentifier": "t_stringliteral_883463e9264686ff6579152095fa8091087bec17866dd00fe5d0be20efb0af5b",
                                  "typeString": "literal_string \"Bad _extraData signature. Call must be to tbtcToBtc.\""
                                }
                              ],
                              "overloadedDeclarations": [
                                18363,
                                18364
                              ],
                              "referencedDeclaration": 18364,
                              "type": "function (bool,string memory) pure",
                              "value": "require"
                            },
                            "id": 6166,
                            "name": "Identifier",
                            "src": "2269:7:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "commonType": {
                                "typeIdentifier": "t_bytes4",
                                "typeString": "bytes4"
                              },
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "operator": "==",
                              "type": "bool"
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "overloadedDeclarations": [
                                    null
                                  ],
                                  "referencedDeclaration": 6163,
                                  "type": "bytes4",
                                  "value": "functionSignature"
                                },
                                "id": 6167,
                                "name": "Identifier",
                                "src": "2290:17:17"
                              },
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": false,
                                  "lValueRequested": false,
                                  "member_name": "selector",
                                  "referencedDeclaration": null,
                                  "type": "bytes4"
                                },
                                "children": [
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": false,
                                      "lValueRequested": false,
                                      "member_name": "tbtcToBtc",
                                      "referencedDeclaration": 9122,
                                      "type": "function (address payable,bytes8,bytes memory) external"
                                    },
                                    "children": [
                                      {
                                        "attributes": {
                                          "argumentTypes": null,
                                          "overloadedDeclarations": [
                                            null
                                          ],
                                          "referencedDeclaration": 6092,
                                          "type": "contract VendingMachine",
                                          "value": "vendingMachine"
                                        },
                                        "id": 6168,
                                        "name": "Identifier",
                                        "src": "2311:14:17"
                                      }
                                    ],
                                    "id": 6169,
                                    "name": "MemberAccess",
                                    "src": "2311:24:17"
                                  }
                                ],
                                "id": 6170,
                                "name": "MemberAccess",
                                "src": "2311:33:17"
                              }
                            ],
                            "id": 6171,
                            "name": "BinaryOperation",
                            "src": "2290:54:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "hexvalue": "426164205f657874726144617461207369676e61747572652e2043616c6c206d75737420626520746f2074627463546f4274632e",
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": true,
                              "lValueRequested": false,
                              "subdenomination": null,
                              "token": "string",
                              "type": "literal_string \"Bad _extraData signature. Call must be to tbtcToBtc.\"",
                              "value": "Bad _extraData signature. Call must be to tbtcToBtc."
                            },
                            "id": 6172,
                            "name": "Literal",
                            "src": "2358:54:17"
                          }
                        ],
                        "id": 6173,
                        "name": "FunctionCall",
                        "src": "2269:153:17"
                      }
                    ],
                    "id": 6174,
                    "name": "ExpressionStatement",
                    "src": "2269:153:17"
                  },
                  {
                    "attributes": {
                      "assignments": [
                        6176,
                        6178
                      ]
                    },
                    "children": [
                      {
                        "attributes": {
                          "constant": false,
                          "name": "success",
                          "scope": 6195,
                          "stateVariable": false,
                          "storageLocation": "default",
                          "type": "bool",
                          "value": null,
                          "visibility": "internal"
                        },
                        "children": [
                          {
                            "attributes": {
                              "name": "bool",
                              "type": "bool"
                            },
                            "id": 6175,
                            "name": "ElementaryTypeName",
                            "src": "2618:4:17"
                          }
                        ],
                        "id": 6176,
                        "name": "VariableDeclaration",
                        "src": "2618:12:17"
                      },
                      {
                        "attributes": {
                          "constant": false,
                          "name": "returnData",
                          "scope": 6195,
                          "stateVariable": false,
                          "storageLocation": "memory",
                          "type": "bytes",
                          "value": null,
                          "visibility": "internal"
                        },
                        "children": [
                          {
                            "attributes": {
                              "name": "bytes",
                              "type": "bytes"
                            },
                            "id": 6177,
                            "name": "ElementaryTypeName",
                            "src": "2632:5:17"
                          }
                        ],
                        "id": 6178,
                        "name": "VariableDeclaration",
                        "src": "2632:23:17"
                      },
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "isStructConstructorCall": false,
                          "lValueRequested": false,
                          "names": [
                            null
                          ],
                          "type": "tuple(bool,bytes memory)",
                          "type_conversion": false
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": [
                                {
                                  "typeIdentifier": "t_bytes_memory_ptr",
                                  "typeString": "bytes memory"
                                }
                              ],
                              "isConstant": false,
                              "isLValue": false,
                              "isPure": false,
                              "lValueRequested": false,
                              "member_name": "call",
                              "referencedDeclaration": null,
                              "type": "function (bytes memory) payable returns (bool,bytes memory)"
                            },
                            "children": [
                              {
                                "attributes": {
                                  "argumentTypes": null,
                                  "isConstant": false,
                                  "isLValue": false,
                                  "isPure": false,
                                  "isStructConstructorCall": false,
                                  "lValueRequested": false,
                                  "names": [
                                    null
                                  ],
                                  "type": "address",
                                  "type_conversion": true
                                },
                                "children": [
                                  {
                                    "attributes": {
                                      "argumentTypes": [
                                        {
                                          "typeIdentifier": "t_contract$_VendingMachine_$9123",
                                          "typeString": "contract VendingMachine"
                                        }
                                      ],
                                      "isConstant": false,
                                      "isLValue": false,
                                      "isPure": true,
                                      "lValueRequested": false,
                                      "type": "type(address)",
                                      "value": "address"
                                    },
                                    "id": 6179,
                                    "name": "ElementaryTypeNameExpression",
                                    "src": "2671:7:17"
                                  },
                                  {
                                    "attributes": {
                                      "argumentTypes": null,
                                      "overloadedDeclarations": [
                                        null
                                      ],
                                      "referencedDeclaration": 6092,
                                      "type": "contract VendingMachine",
                                      "value": "vendingMachine"
                                    },
                                    "id": 6180,
                                    "name": "Identifier",
                                    "src": "2679:14:17"
                                  }
                                ],
                                "id": 6181,
                                "name": "FunctionCall",
                                "src": "2671:23:17"
                              }
                            ],
                            "id": 6182,
                            "name": "MemberAccess",
                            "src": "2671:28:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 6130,
                              "type": "bytes memory",
                              "value": "_extraData"
                            },
                            "id": 6183,
                            "name": "Identifier",
                            "src": "2700:10:17"
                          }
                        ],
                        "id": 6184,
                        "name": "FunctionCall",
                        "src": "2671:40:17"
                      }
                    ],
                    "id": 6185,
                    "name": "VariableDeclarationStatement",
                    "src": "2617:94:17"
                  },
                  {
                    "attributes": {
                      "assignments": [
                        6187
                      ],
                      "initialValue": null
                    },
                    "children": [
                      {
                        "attributes": {
                          "constant": false,
                          "name": "revertMessage",
                          "scope": 6195,
                          "stateVariable": false,
                          "storageLocation": "memory",
                          "type": "string",
                          "value": null,
                          "visibility": "internal"
                        },
                        "children": [
                          {
                            "attributes": {
                              "name": "string",
                              "type": "string"
                            },
                            "id": 6186,
                            "name": "ElementaryTypeName",
                            "src": "2722:6:17"
                          }
                        ],
                        "id": 6187,
                        "name": "VariableDeclaration",
                        "src": "2722:27:17"
                      }
                    ],
                    "id": 6188,
                    "name": "VariableDeclarationStatement",
                    "src": "2722:27:17"
                  },
                  {
                    "attributes": {
                      "externalReferences": [
                        {
                          "revertMessage": {
                            "declaration": 6187,
                            "isOffset": false,
                            "isSlot": false,
                            "src": "3064:13:17",
                            "valueSize": 1
                          }
                        },
                        {
                          "returnData": {
                            "declaration": 6178,
                            "isOffset": false,
                            "isSlot": false,
                            "src": "3085:10:17",
                            "valueSize": 1
                          }
                        }
                      ],
                      "operations": "{\n    revertMessage := add(returnData, 0x44)\n}"
                    },
                    "children": [],
                    "id": 6189,
                    "name": "InlineAssembly",
                    "src": "2759:353:17"
                  },
                  {
                    "children": [
                      {
                        "attributes": {
                          "argumentTypes": null,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": false,
                          "isStructConstructorCall": false,
                          "lValueRequested": false,
                          "names": [
                            null
                          ],
                          "type": "tuple()",
                          "type_conversion": false
                        },
                        "children": [
                          {
                            "attributes": {
                              "argumentTypes": [
                                {
                                  "typeIdentifier": "t_bool",
                                  "typeString": "bool"
                                },
                                {
                                  "typeIdentifier": "t_string_memory_ptr",
                                  "typeString": "string memory"
                                }
                              ],
                              "overloadedDeclarations": [
                                18363,
                                18364
                              ],
                              "referencedDeclaration": 18364,
                              "type": "function (bool,string memory) pure",
                              "value": "require"
                            },
                            "id": 6190,
                            "name": "Identifier",
                            "src": "3122:7:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 6176,
                              "type": "bool",
                              "value": "success"
                            },
                            "id": 6191,
                            "name": "Identifier",
                            "src": "3130:7:17"
                          },
                          {
                            "attributes": {
                              "argumentTypes": null,
                              "overloadedDeclarations": [
                                null
                              ],
                              "referencedDeclaration": 6187,
                              "type": "string memory",
                              "value": "revertMessage"
                            },
                            "id": 6192,
                            "name": "Identifier",
                            "src": "3139:13:17"
                          }
                        ],
                        "id": 6193,
                        "name": "FunctionCall",
                        "src": "3122:31:17"
                      }
                    ],
                    "id": 6194,
                    "name": "ExpressionStatement",
                    "src": "3122:31:17"
                  }
                ],
                "id": 6195,
                "name": "Block",
                "src": "1749:1411:17"
              }
            ],
            "id": 6196,
            "name": "FunctionDefinition",
            "src": "1613:1547:17"
          }
        ],
        "id": 6197,
        "name": "ContractDefinition",
        "src": "760:2402:17"
      }
    ],
    "id": 6198,
    "name": "SourceUnit",
    "src": "0:3163:17"
  },
  "compiler": {
    "name": "solc",
    "version": "0.5.17+commit.d19bba13.Emscripten.clang"
  },
  "networks": {
    "3": {
      "events": {},
      "links": {},
      "address": "0x30A29C78A1ff30cb8243664E82938d8bd3c63eC4",
      "transactionHash": "0x7968e1faa66ded5f525745b07589fed23d4a0913cf750c46faccc25da42815a0"
    }
  },
  "schemaVersion": "3.3.4",
  "updatedAt": "2021-11-23T12:01:17.320Z",
  "networkType": "ethereum",
  "devdoc": {
    "details": "Wrapper script for VendingMachine.tbtcToBtc This contract implements receiveApproval() and can therefore use approveAndCall(). This pattern combines TBTC Token approval and vendingMachine.tbtcToBtc() in a single transaction.",
    "methods": {
      "receiveApproval(address,uint256,address,bytes)": {
        "details": "Implements the approveAndCall receiver interface.",
        "params": {
          "_amount": "Approved TBTC amount for the transfer.",
          "_extraData": "Encoded function call to `VendingMachine.tbtcToBtc`.",
          "_from": "The owner of the token who approved them for transfer."
        }
      }
    }
  },
  "userdoc": {
    "methods": {
      "receiveApproval(address,uint256,address,bytes)": {
        "notice": "Receives approval for a TBTC transfer, and calls `VendingMachine.tbtcToBtc` for a user."
      }
    },
    "notice": "A one-click script for redeeming TBTC into BTC."
  }
}