UNPKG

@etherisc/depeg-contracts

Version:

Etherisc's smart contracts for a depeg insurance for stable coins.

1,256 lines (1,255 loc) 109 kB
{ "abi": [ { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "bool", "name": "callSuccess", "type": "bool" }, { "indexed": false, "internalType": "uint256", "name": "returnDataLength", "type": "uint256" }, { "indexed": false, "internalType": "bytes", "name": "returnData", "type": "bytes" } ], "name": "LogTransferHelperCallFailed", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "bool", "name": "tokenIsContract", "type": "bool" }, { "indexed": false, "internalType": "address", "name": "from", "type": "address" }, { "indexed": false, "internalType": "address", "name": "to", "type": "address" } ], "name": "LogTransferHelperInputValidation1Failed", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "balance", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "allowance", "type": "uint256" } ], "name": "LogTransferHelperInputValidation2Failed", "type": "event" } ], "allSourcePaths": { "23": "/home/vscode/.brownie/packages/etherisc/gif-contracts@b58fd27/contracts/shared/TransferHelper.sol", "4": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/token/ERC20/IERC20.sol" }, "ast": { "absolutePath": "/home/vscode/.brownie/packages/etherisc/gif-contracts@b58fd27/contracts/shared/TransferHelper.sol", "exportedSymbols": { "IERC20": [ 15820 ], "TransferHelper": [ 21821 ] }, "id": 21822, "license": "Apache-2.0", "nodeType": "SourceUnit", "nodes": [ { "id": 21651, "literals": [ "solidity", "0.8", ".2" ], "nodeType": "PragmaDirective", "src": "39:22:23" }, { "absolutePath": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.7.3/contracts/token/ERC20/IERC20.sol", "file": "@openzeppelin/contracts/token/ERC20/IERC20.sol", "id": 21652, "nameLocation": "-1:-1:-1", "nodeType": "ImportDirective", "scope": 21822, "sourceUnit": 15821, "src": "63:56:23", "symbolAliases": [], "unitAlias": "" }, { "abstract": false, "baseContracts": [], "contractDependencies": [], "contractKind": "library", "fullyImplemented": true, "id": 21821, "linearizedBaseContracts": [ 21821 ], "name": "TransferHelper", "nameLocation": "603:14:23", "nodeType": "ContractDefinition", "nodes": [ { "anonymous": false, "id": 21660, "name": "LogTransferHelperInputValidation1Failed", "nameLocation": "631:39:23", "nodeType": "EventDefinition", "parameters": { "id": 21659, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 21654, "indexed": false, "mutability": "mutable", "name": "tokenIsContract", "nameLocation": "676:15:23", "nodeType": "VariableDeclaration", "scope": 21660, "src": "671:20:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 21653, "name": "bool", "nodeType": "ElementaryTypeName", "src": "671:4:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "visibility": "internal" }, { "constant": false, "id": 21656, "indexed": false, "mutability": "mutable", "name": "from", "nameLocation": "701:4:23", "nodeType": "VariableDeclaration", "scope": 21660, "src": "693:12:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 21655, "name": "address", "nodeType": "ElementaryTypeName", "src": "693:7:23", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" }, { "constant": false, "id": 21658, "indexed": false, "mutability": "mutable", "name": "to", "nameLocation": "715:2:23", "nodeType": "VariableDeclaration", "scope": 21660, "src": "707:10:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 21657, "name": "address", "nodeType": "ElementaryTypeName", "src": "707:7:23", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" } ], "src": "670:48:23" }, "src": "625:94:23" }, { "anonymous": false, "id": 21666, "name": "LogTransferHelperInputValidation2Failed", "nameLocation": "730:39:23", "nodeType": "EventDefinition", "parameters": { "id": 21665, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 21662, "indexed": false, "mutability": "mutable", "name": "balance", "nameLocation": "778:7:23", "nodeType": "VariableDeclaration", "scope": 21666, "src": "770:15:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 21661, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "770:7:23", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" }, { "constant": false, "id": 21664, "indexed": false, "mutability": "mutable", "name": "allowance", "nameLocation": "795:9:23", "nodeType": "VariableDeclaration", "scope": 21666, "src": "787:17:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 21663, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "787:7:23", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "src": "769:36:23" }, "src": "724:82:23" }, { "anonymous": false, "id": 21674, "name": "LogTransferHelperCallFailed", "nameLocation": "817:27:23", "nodeType": "EventDefinition", "parameters": { "id": 21673, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 21668, "indexed": false, "mutability": "mutable", "name": "callSuccess", "nameLocation": "850:11:23", "nodeType": "VariableDeclaration", "scope": 21674, "src": "845:16:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 21667, "name": "bool", "nodeType": "ElementaryTypeName", "src": "845:4:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "visibility": "internal" }, { "constant": false, "id": 21670, "indexed": false, "mutability": "mutable", "name": "returnDataLength", "nameLocation": "871:16:23", "nodeType": "VariableDeclaration", "scope": 21674, "src": "863:24:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 21669, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "863:7:23", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" }, { "constant": false, "id": 21672, "indexed": false, "mutability": "mutable", "name": "returnData", "nameLocation": "895:10:23", "nodeType": "VariableDeclaration", "scope": 21674, "src": "889:16:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bytes_memory_ptr", "typeString": "bytes" }, "typeName": { "id": 21671, "name": "bytes", "nodeType": "ElementaryTypeName", "src": "889:5:23", "typeDescriptions": { "typeIdentifier": "t_bytes_storage_ptr", "typeString": "bytes" } }, "visibility": "internal" } ], "src": "844:62:23" }, "src": "811:96:23" }, { "body": { "id": 21819, "nodeType": "Block", "src": "1086:1249:23", "statements": [ { "assignments": [ 21689 ], "declarations": [ { "constant": false, "id": 21689, "mutability": "mutable", "name": "tokenAddress", "nameLocation": "1139:12:23", "nodeType": "VariableDeclaration", "scope": 21819, "src": "1131:20:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 21688, "name": "address", "nodeType": "ElementaryTypeName", "src": "1131:7:23", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "visibility": "internal" } ], "id": 21694, "initialValue": { "arguments": [ { "id": 21692, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21677, "src": "1162:5:23", "typeDescriptions": { "typeIdentifier": "t_contract$_IERC20_$15820", "typeString": "contract IERC20" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_contract$_IERC20_$15820", "typeString": "contract IERC20" } ], "id": 21691, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "1154:7:23", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": { "id": 21690, "name": "address", "nodeType": "ElementaryTypeName", "src": "1154:7:23", "typeDescriptions": {} } }, "id": 21693, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1154:14:23", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "VariableDeclarationStatement", "src": "1131:37:23" }, { "assignments": [ 21696 ], "declarations": [ { "constant": false, "id": 21696, "mutability": "mutable", "name": "tokenIsContract", "nameLocation": "1183:15:23", "nodeType": "VariableDeclaration", "scope": 21819, "src": "1178:20:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 21695, "name": "bool", "nodeType": "ElementaryTypeName", "src": "1178:4:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "visibility": "internal" } ], "id": 21703, "initialValue": { "components": [ { "commonType": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "id": 21701, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "expression": { "expression": { "id": 21697, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21689, "src": "1202:12:23", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "id": 21698, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "code", "nodeType": "MemberAccess", "src": "1202:17:23", "typeDescriptions": { "typeIdentifier": "t_bytes_memory_ptr", "typeString": "bytes memory" } }, "id": 21699, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "length", "nodeType": "MemberAccess", "src": "1202:24:23", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "BinaryOperation", "operator": ">", "rightExpression": { "hexValue": "30", "id": 21700, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", "src": "1229:1:23", "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", "typeString": "int_const 0" }, "value": "0" }, "src": "1202:28:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } } ], "id": 21702, "isConstant": false, "isInlineArray": false, "isLValue": false, "isPure": false, "lValueRequested": false, "nodeType": "TupleExpression", "src": "1201:30:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "VariableDeclarationStatement", "src": "1178:53:23" }, { "condition": { "commonType": { "typeIdentifier": "t_bool", "typeString": "bool" }, "id": 21719, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "commonType": { "typeIdentifier": "t_bool", "typeString": "bool" }, "id": 21716, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "commonType": { "typeIdentifier": "t_address", "typeString": "address" }, "id": 21709, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "id": 21704, "name": "from", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21679, "src": "1245:4:23", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "BinaryOperation", "operator": "==", "rightExpression": { "arguments": [ { "hexValue": "30", "id": 21707, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", "src": "1261:1:23", "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", "typeString": "int_const 0" }, "value": "0" } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_rational_0_by_1", "typeString": "int_const 0" } ], "id": 21706, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "1253:7:23", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": { "id": 21705, "name": "address", "nodeType": "ElementaryTypeName", "src": "1253:7:23", "typeDescriptions": {} } }, "id": 21708, "isConstant": false, "isLValue": false, "isPure": true, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1253:10:23", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "src": "1245:18:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "BinaryOperation", "operator": "||", "rightExpression": { "commonType": { "typeIdentifier": "t_address", "typeString": "address" }, "id": 21715, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "id": 21710, "name": "to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21681, "src": "1267:2:23", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "BinaryOperation", "operator": "==", "rightExpression": { "arguments": [ { "hexValue": "30", "id": 21713, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", "src": "1282:1:23", "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", "typeString": "int_const 0" }, "value": "0" } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_rational_0_by_1", "typeString": "int_const 0" } ], "id": 21712, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "1273:7:23", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": { "id": 21711, "name": "address", "nodeType": "ElementaryTypeName", "src": "1273:7:23", "typeDescriptions": {} } }, "id": 21714, "isConstant": false, "isLValue": false, "isPure": true, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1273:11:23", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "src": "1267:17:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "src": "1245:39:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "nodeType": "BinaryOperation", "operator": "||", "rightExpression": { "id": 21718, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "nodeType": "UnaryOperation", "operator": "!", "prefix": true, "src": "1288:16:23", "subExpression": { "id": 21717, "name": "tokenIsContract", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21696, "src": "1289:15:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "src": "1245:59:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "id": 21729, "nodeType": "IfStatement", "src": "1241:187:23", "trueBody": { "id": 21728, "nodeType": "Block", "src": "1306:122:23", "statements": [ { "eventCall": { "arguments": [ { "id": 21721, "name": "tokenIsContract", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21696, "src": "1365:15:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, { "id": 21722, "name": "from", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21679, "src": "1382:4:23", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "id": 21723, "name": "to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21681, "src": "1388:2:23", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_bool", "typeString": "bool" }, { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_address", "typeString": "address" } ], "id": 21720, "name": "LogTransferHelperInputValidation1Failed", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21660, "src": "1325:39:23", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_bool_$_t_address_$_t_address_$returns$__$", "typeString": "function (bool,address,address)" } }, "id": 21724, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1325:66:23", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 21725, "nodeType": "EmitStatement", "src": "1320:71:23" }, { "expression": { "hexValue": "66616c7365", "id": 21726, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", "src": "1412:5:23", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "value": "false" }, "functionReturnParameters": 21687, "id": 21727, "nodeType": "Return", "src": "1405:12:23" } ] } }, { "assignments": [ 21731 ], "declarations": [ { "constant": false, "id": 21731, "mutability": "mutable", "name": "balance", "nameLocation": "1489:7:23", "nodeType": "VariableDeclaration", "scope": 21819, "src": "1481:15:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 21730, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1481:7:23", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "id": 21736, "initialValue": { "arguments": [ { "id": 21734, "name": "from", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21679, "src": "1515:4:23", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" } ], "expression": { "id": 21732, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21677, "src": "1499:5:23", "typeDescriptions": { "typeIdentifier": "t_contract$_IERC20_$15820", "typeString": "contract IERC20" } }, "id": 21733, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "balanceOf", "nodeType": "MemberAccess", "referencedDeclaration": 15777, "src": "1499:15:23", "typeDescriptions": { "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", "typeString": "function (address) view external returns (uint256)" } }, "id": 21735, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1499:21:23", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", "src": "1481:39:23" }, { "assignments": [ 21738 ], "declarations": [ { "constant": false, "id": 21738, "mutability": "mutable", "name": "allowance", "nameLocation": "1538:9:23", "nodeType": "VariableDeclaration", "scope": 21819, "src": "1530:17:23", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 21737, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1530:7:23", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "visibility": "internal" } ], "id": 21747, "initialValue": { "arguments": [ { "id": 21741, "name": "from", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21679, "src": "1566:4:23", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "arguments": [ { "id": 21744, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -28, "src": "1580:4:23", "typeDescriptions": { "typeIdentifier": "t_contract$_TransferHelper_$21821", "typeString": "library TransferHelper" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_contract$_TransferHelper_$21821", "typeString": "library TransferHelper" } ], "id": 21743, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "1572:7:23", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": { "id": 21742, "name": "address", "nodeType": "ElementaryTypeName", "src": "1572:7:23", "typeDescriptions": {} } }, "id": 21745, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1572:13:23", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_address", "typeString": "address" } ], "expression": { "id": 21739, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 21677, "src": "1550:5:23", "typeDescriptions": { "typeIdentifier": "t_contract$_IERC20_$15820", "typeString": "contract IERC20" } }, "id": 21740, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "allowance", "nodeType": "MemberAccess", "referencedDeclaration": 15797, "src": "1550:15:23", "typeDescriptions": { "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", "typeString": "function (address,address) view external returns (uint256)" } }, "id": 21746, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1550:36:23", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", "src": "1530:56:23" }, { "condition": { "commonType": { "typeIdentifier": "t_bool", "typeString": "bool" }, "id": 21754, "isConstant": false, "isLValue": false,