4450 lines
181 KiB
JSON
4450 lines
181 KiB
JSON
{
|
|
"abi": [],
|
|
"bytecode": {
|
|
"object": "0x60808060405234601757603a9081601d823930815050f35b600080fdfe600080fdfea2646970667358221220392fa9cebfd94ad7174ca31cd489bc62c065ccdd62a9645aa035d347486e607764736f6c63430008110033",
|
|
"sourceMap": "194:8964:22:-:0;;;;;;;;;;;;;;;;;;;;;",
|
|
"linkReferences": {}
|
|
},
|
|
"deployedBytecode": {
|
|
"object": "0x600080fdfea2646970667358221220392fa9cebfd94ad7174ca31cd489bc62c065ccdd62a9645aa035d347486e607764736f6c63430008110033",
|
|
"sourceMap": "194:8964:22:-:0;;",
|
|
"linkReferences": {}
|
|
},
|
|
"methodIdentifiers": {},
|
|
"rawMetadata": "{\"compiler\":{\"version\":\"0.8.17+commit.8df45f5f\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"details\":\"Collection of functions related to the address type\",\"kind\":\"dev\",\"methods\":{},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"node_modules/@openzeppelin/contracts/utils/Address.sol\":\"Address\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[\":@ensdomains/=node_modules/@ensdomains/\",\":@openzeppelin/=node_modules/@openzeppelin/\",\":ds-test/=lib/forge-std/lib/ds-test/src/\",\":eth-gas-reporter/=node_modules/eth-gas-reporter/\",\":forge-std/=lib/forge-std/src/\",\":hardhat-deploy/=node_modules/hardhat-deploy/\",\":hardhat/=node_modules/hardhat/\"],\"viaIR\":true},\"sources\":{\"node_modules/@openzeppelin/contracts/utils/Address.sol\":{\"keccak256\":\"0xf96f969e24029d43d0df89e59d365f277021dac62b48e1c1e3ebe0acdd7f1ca1\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://ec772b45a624be516f1c81970caa8a2e144301e9d0921cbc1a2789fef39a1269\",\"dweb:/ipfs/QmNyjwxCrGhQMyzLD93oUobJXVe9ceJvRvfXwbEtuxPiEj\"]}},\"version\":1}",
|
|
"metadata": {
|
|
"compiler": {
|
|
"version": "0.8.17+commit.8df45f5f"
|
|
},
|
|
"language": "Solidity",
|
|
"output": {
|
|
"abi": [],
|
|
"devdoc": {
|
|
"kind": "dev",
|
|
"methods": {},
|
|
"version": 1
|
|
},
|
|
"userdoc": {
|
|
"kind": "user",
|
|
"methods": {},
|
|
"version": 1
|
|
}
|
|
},
|
|
"settings": {
|
|
"remappings": [
|
|
":@ensdomains/=node_modules/@ensdomains/",
|
|
":@openzeppelin/=node_modules/@openzeppelin/",
|
|
":ds-test/=lib/forge-std/lib/ds-test/src/",
|
|
":eth-gas-reporter/=node_modules/eth-gas-reporter/",
|
|
":forge-std/=lib/forge-std/src/",
|
|
":hardhat-deploy/=node_modules/hardhat-deploy/",
|
|
":hardhat/=node_modules/hardhat/"
|
|
],
|
|
"optimizer": {
|
|
"enabled": true,
|
|
"runs": 200
|
|
},
|
|
"metadata": {
|
|
"bytecodeHash": "ipfs"
|
|
},
|
|
"compilationTarget": {
|
|
"node_modules/@openzeppelin/contracts/utils/Address.sol": "Address"
|
|
},
|
|
"libraries": {},
|
|
"viaIR": true
|
|
},
|
|
"sources": {
|
|
"node_modules/@openzeppelin/contracts/utils/Address.sol": {
|
|
"keccak256": "0xf96f969e24029d43d0df89e59d365f277021dac62b48e1c1e3ebe0acdd7f1ca1",
|
|
"urls": [
|
|
"bzz-raw://ec772b45a624be516f1c81970caa8a2e144301e9d0921cbc1a2789fef39a1269",
|
|
"dweb:/ipfs/QmNyjwxCrGhQMyzLD93oUobJXVe9ceJvRvfXwbEtuxPiEj"
|
|
],
|
|
"license": "MIT"
|
|
}
|
|
},
|
|
"version": 1
|
|
},
|
|
"ast": {
|
|
"absolutePath": "node_modules/@openzeppelin/contracts/utils/Address.sol",
|
|
"id": 27211,
|
|
"exportedSymbols": {
|
|
"Address": [
|
|
27210
|
|
]
|
|
},
|
|
"nodeType": "SourceUnit",
|
|
"src": "101:9058:22",
|
|
"nodes": [
|
|
{
|
|
"id": 26882,
|
|
"nodeType": "PragmaDirective",
|
|
"src": "101:23:22",
|
|
"nodes": [],
|
|
"literals": [
|
|
"solidity",
|
|
"^",
|
|
"0.8",
|
|
".1"
|
|
]
|
|
},
|
|
{
|
|
"id": 27210,
|
|
"nodeType": "ContractDefinition",
|
|
"src": "194:8964:22",
|
|
"nodes": [
|
|
{
|
|
"id": 26898,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "1175:320:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 26897,
|
|
"nodeType": "Block",
|
|
"src": "1241:254:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 26895,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"expression": {
|
|
"expression": {
|
|
"id": 26891,
|
|
"name": "account",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26886,
|
|
"src": "1465:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 26892,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberLocation": "1473:4:22",
|
|
"memberName": "code",
|
|
"nodeType": "MemberAccess",
|
|
"src": "1465:12:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"id": 26893,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberLocation": "1478:6:22",
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"src": "1465:19:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"hexValue": "30",
|
|
"id": 26894,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "1487:1:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "1465:23:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"functionReturnParameters": 26890,
|
|
"id": 26896,
|
|
"nodeType": "Return",
|
|
"src": "1458:30:22"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 26884,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "216:954:22",
|
|
"text": " @dev Returns true if `account` is a contract.\n [IMPORTANT]\n ====\n It is unsafe to assume that an address for which this function returns\n false is an externally-owned account (EOA) and not a contract.\n Among others, `isContract` will return false for the following\n types of addresses:\n - an externally-owned account\n - a contract in construction\n - an address where a contract will be created\n - an address where a contract lived, but was destroyed\n ====\n [IMPORTANT]\n ====\n You shouldn't rely on `isContract` to protect against flash loan attacks!\n Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets\n like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract\n constructor.\n ===="
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "isContract",
|
|
"nameLocation": "1184:10:22",
|
|
"parameters": {
|
|
"id": 26887,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 26886,
|
|
"mutability": "mutable",
|
|
"name": "account",
|
|
"nameLocation": "1203:7:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26898,
|
|
"src": "1195:15:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 26885,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1195:7:22",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1194:17:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 26890,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 26889,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nameLocation": "-1:-1:-1",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26898,
|
|
"src": "1235:4:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 26888,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1235:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1234:6:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "view",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 26932,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "2412:312:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 26931,
|
|
"nodeType": "Block",
|
|
"src": "2483:241:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 26913,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 26909,
|
|
"name": "this",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": -28,
|
|
"src": "2509:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_Address_$27210",
|
|
"typeString": "library Address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_Address_$27210",
|
|
"typeString": "library Address"
|
|
}
|
|
],
|
|
"id": 26908,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "2501:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": {
|
|
"id": 26907,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2501:7:22",
|
|
"typeDescriptions": {}
|
|
}
|
|
},
|
|
"id": 26910,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2501:13:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 26911,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberLocation": "2515:7:22",
|
|
"memberName": "balance",
|
|
"nodeType": "MemberAccess",
|
|
"src": "2501:21:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">=",
|
|
"rightExpression": {
|
|
"id": 26912,
|
|
"name": "amount",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26903,
|
|
"src": "2526:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "2501:31:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
{
|
|
"hexValue": "416464726573733a20696e73756666696369656e742062616c616e6365",
|
|
"id": 26914,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "2534:31:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_5597a22abd0ef5332f8053862eb236db7590f17e2b93a53f63a103becfb561f9",
|
|
"typeString": "literal_string \"Address: insufficient balance\""
|
|
},
|
|
"value": "Address: insufficient balance"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_stringliteral_5597a22abd0ef5332f8053862eb236db7590f17e2b93a53f63a103becfb561f9",
|
|
"typeString": "literal_string \"Address: insufficient balance\""
|
|
}
|
|
],
|
|
"id": 26906,
|
|
"name": "require",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
-18,
|
|
-18
|
|
],
|
|
"referencedDeclaration": -18,
|
|
"src": "2493:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
|
|
"typeString": "function (bool,string memory) pure"
|
|
}
|
|
},
|
|
"id": 26915,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2493:73:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 26916,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2493:73:22"
|
|
},
|
|
{
|
|
"assignments": [
|
|
26918,
|
|
null
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 26918,
|
|
"mutability": "mutable",
|
|
"name": "success",
|
|
"nameLocation": "2583:7:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26931,
|
|
"src": "2578:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 26917,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2578:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
null
|
|
],
|
|
"id": 26925,
|
|
"initialValue": {
|
|
"arguments": [
|
|
{
|
|
"hexValue": "",
|
|
"id": 26923,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "2626:2:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",
|
|
"typeString": "literal_string \"\""
|
|
},
|
|
"value": ""
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_stringliteral_c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",
|
|
"typeString": "literal_string \"\""
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_stringliteral_c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",
|
|
"typeString": "literal_string \"\""
|
|
}
|
|
],
|
|
"expression": {
|
|
"id": 26919,
|
|
"name": "recipient",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26901,
|
|
"src": "2596:9:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address_payable",
|
|
"typeString": "address payable"
|
|
}
|
|
},
|
|
"id": 26920,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberLocation": "2606:4:22",
|
|
"memberName": "call",
|
|
"nodeType": "MemberAccess",
|
|
"src": "2596:14:22",
|
|
"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": 26922,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"names": [
|
|
"value"
|
|
],
|
|
"nodeType": "FunctionCallOptions",
|
|
"options": [
|
|
{
|
|
"id": 26921,
|
|
"name": "amount",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26903,
|
|
"src": "2618:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"src": "2596:29:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_barecall_payable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$value",
|
|
"typeString": "function (bytes memory) payable returns (bool,bytes memory)"
|
|
}
|
|
},
|
|
"id": 26924,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2596:33:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
|
|
"typeString": "tuple(bool,bytes memory)"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "2577:52:22"
|
|
},
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 26927,
|
|
"name": "success",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26918,
|
|
"src": "2647:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
{
|
|
"hexValue": "416464726573733a20756e61626c6520746f2073656e642076616c75652c20726563697069656e74206d61792068617665207265766572746564",
|
|
"id": 26928,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "2656:60:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_51ddaa38748c0a1144620fb5bfe8edab31ea437571ad591a7734bbfd0429aeae",
|
|
"typeString": "literal_string \"Address: unable to send value, recipient may have reverted\""
|
|
},
|
|
"value": "Address: unable to send value, recipient may have reverted"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_stringliteral_51ddaa38748c0a1144620fb5bfe8edab31ea437571ad591a7734bbfd0429aeae",
|
|
"typeString": "literal_string \"Address: unable to send value, recipient may have reverted\""
|
|
}
|
|
],
|
|
"id": 26926,
|
|
"name": "require",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
-18,
|
|
-18
|
|
],
|
|
"referencedDeclaration": -18,
|
|
"src": "2639:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
|
|
"typeString": "function (bool,string memory) pure"
|
|
}
|
|
},
|
|
"id": 26929,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2639:78:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 26930,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2639:78:22"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 26899,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "1501:906:22",
|
|
"text": " @dev Replacement for Solidity's `transfer`: sends `amount` wei to\n `recipient`, forwarding all available gas and reverting on errors.\n https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost\n of certain opcodes, possibly making contracts go over the 2300 gas limit\n imposed by `transfer`, making them unable to receive funds via\n `transfer`. {sendValue} removes this limitation.\n https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].\n IMPORTANT: because control is transferred to `recipient`, care must be\n taken to not create reentrancy vulnerabilities. Consider using\n {ReentrancyGuard} or the\n https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]."
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "sendValue",
|
|
"nameLocation": "2421:9:22",
|
|
"parameters": {
|
|
"id": 26904,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 26901,
|
|
"mutability": "mutable",
|
|
"name": "recipient",
|
|
"nameLocation": "2447:9:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26932,
|
|
"src": "2431:25:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address_payable",
|
|
"typeString": "address payable"
|
|
},
|
|
"typeName": {
|
|
"id": 26900,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2431:15:22",
|
|
"stateMutability": "payable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address_payable",
|
|
"typeString": "address payable"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 26903,
|
|
"mutability": "mutable",
|
|
"name": "amount",
|
|
"nameLocation": "2466:6:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26932,
|
|
"src": "2458:14:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 26902,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2458:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "2430:43:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 26905,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "2483:0:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "nonpayable",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 26950,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "3466:185:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 26949,
|
|
"nodeType": "Block",
|
|
"src": "3555:96:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 26943,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26935,
|
|
"src": "3594:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"id": 26944,
|
|
"name": "data",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26937,
|
|
"src": "3602:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
{
|
|
"hexValue": "30",
|
|
"id": 26945,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3608:1:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
{
|
|
"hexValue": "416464726573733a206c6f772d6c6576656c2063616c6c206661696c6564",
|
|
"id": 26946,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3611:32:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_24d7ab5d382116e64324f19950ca9340b8af1ddeb09a8d026e0a3c6a01dcc9df",
|
|
"typeString": "literal_string \"Address: low-level call failed\""
|
|
},
|
|
"value": "Address: low-level call failed"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_stringliteral_24d7ab5d382116e64324f19950ca9340b8af1ddeb09a8d026e0a3c6a01dcc9df",
|
|
"typeString": "literal_string \"Address: low-level call failed\""
|
|
}
|
|
],
|
|
"id": 26942,
|
|
"name": "functionCallWithValue",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
26990,
|
|
27034
|
|
],
|
|
"referencedDeclaration": 27034,
|
|
"src": "3572:21:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_bytes_memory_ptr_$_t_uint256_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
|
|
"typeString": "function (address,bytes memory,uint256,string memory) returns (bytes memory)"
|
|
}
|
|
},
|
|
"id": 26947,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3572:72:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 26941,
|
|
"id": 26948,
|
|
"nodeType": "Return",
|
|
"src": "3565:79:22"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 26933,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "2730:731:22",
|
|
"text": " @dev Performs a Solidity function call using a low level `call`. A\n plain `call` is an unsafe replacement for a function call: use this\n function instead.\n If `target` reverts with a revert reason, it is bubbled up by this\n function (like regular Solidity function calls).\n Returns the raw returned data. To convert to the expected return value,\n use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].\n Requirements:\n - `target` must be a contract.\n - calling `target` with `data` must not revert.\n _Available since v3.1._"
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "functionCall",
|
|
"nameLocation": "3475:12:22",
|
|
"parameters": {
|
|
"id": 26938,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 26935,
|
|
"mutability": "mutable",
|
|
"name": "target",
|
|
"nameLocation": "3496:6:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26950,
|
|
"src": "3488:14:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 26934,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3488:7:22",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 26937,
|
|
"mutability": "mutable",
|
|
"name": "data",
|
|
"nameLocation": "3517:4:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26950,
|
|
"src": "3504:17:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 26936,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3504:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3487:35:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 26941,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 26940,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nameLocation": "-1:-1:-1",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26950,
|
|
"src": "3541:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 26939,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3541:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3540:14:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "nonpayable",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 26970,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "3873:223:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 26969,
|
|
"nodeType": "Block",
|
|
"src": "4020:76:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 26963,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26953,
|
|
"src": "4059:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"id": 26964,
|
|
"name": "data",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26955,
|
|
"src": "4067:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
{
|
|
"hexValue": "30",
|
|
"id": 26965,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4073:1:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
{
|
|
"id": 26966,
|
|
"name": "errorMessage",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26957,
|
|
"src": "4076:12:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
],
|
|
"id": 26962,
|
|
"name": "functionCallWithValue",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
26990,
|
|
27034
|
|
],
|
|
"referencedDeclaration": 27034,
|
|
"src": "4037:21:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_bytes_memory_ptr_$_t_uint256_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
|
|
"typeString": "function (address,bytes memory,uint256,string memory) returns (bytes memory)"
|
|
}
|
|
},
|
|
"id": 26967,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "4037:52:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 26961,
|
|
"id": 26968,
|
|
"nodeType": "Return",
|
|
"src": "4030:59:22"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 26951,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "3657:211:22",
|
|
"text": " @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with\n `errorMessage` as a fallback revert reason when `target` reverts.\n _Available since v3.1._"
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "functionCall",
|
|
"nameLocation": "3882:12:22",
|
|
"parameters": {
|
|
"id": 26958,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 26953,
|
|
"mutability": "mutable",
|
|
"name": "target",
|
|
"nameLocation": "3912:6:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26970,
|
|
"src": "3904:14:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 26952,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3904:7:22",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 26955,
|
|
"mutability": "mutable",
|
|
"name": "data",
|
|
"nameLocation": "3941:4:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26970,
|
|
"src": "3928:17:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 26954,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3928:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 26957,
|
|
"mutability": "mutable",
|
|
"name": "errorMessage",
|
|
"nameLocation": "3969:12:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26970,
|
|
"src": "3955:26:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string"
|
|
},
|
|
"typeName": {
|
|
"id": 26956,
|
|
"name": "string",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3955:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage_ptr",
|
|
"typeString": "string"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3894:93:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 26961,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 26960,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nameLocation": "-1:-1:-1",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26970,
|
|
"src": "4006:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 26959,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4006:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "4005:14:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "nonpayable",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 26990,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "4458:254:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 26989,
|
|
"nodeType": "Block",
|
|
"src": "4601:111:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 26983,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26973,
|
|
"src": "4640:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"id": 26984,
|
|
"name": "data",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26975,
|
|
"src": "4648:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
{
|
|
"id": 26985,
|
|
"name": "value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26977,
|
|
"src": "4654:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
{
|
|
"hexValue": "416464726573733a206c6f772d6c6576656c2063616c6c20776974682076616c7565206661696c6564",
|
|
"id": 26986,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4661:43:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_88a4a0b5e975840320a0475d4027005235904fdb5ece94df156f3d717cb2dbfc",
|
|
"typeString": "literal_string \"Address: low-level call with value failed\""
|
|
},
|
|
"value": "Address: low-level call with value failed"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_stringliteral_88a4a0b5e975840320a0475d4027005235904fdb5ece94df156f3d717cb2dbfc",
|
|
"typeString": "literal_string \"Address: low-level call with value failed\""
|
|
}
|
|
],
|
|
"id": 26982,
|
|
"name": "functionCallWithValue",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
26990,
|
|
27034
|
|
],
|
|
"referencedDeclaration": 27034,
|
|
"src": "4618:21:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_bytes_memory_ptr_$_t_uint256_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
|
|
"typeString": "function (address,bytes memory,uint256,string memory) returns (bytes memory)"
|
|
}
|
|
},
|
|
"id": 26987,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "4618:87:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 26981,
|
|
"id": 26988,
|
|
"nodeType": "Return",
|
|
"src": "4611:94:22"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 26971,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "4102:351:22",
|
|
"text": " @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n but also transferring `value` wei to `target`.\n Requirements:\n - the calling contract must have an ETH balance of at least `value`.\n - the called Solidity function must be `payable`.\n _Available since v3.1._"
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "functionCallWithValue",
|
|
"nameLocation": "4467:21:22",
|
|
"parameters": {
|
|
"id": 26978,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 26973,
|
|
"mutability": "mutable",
|
|
"name": "target",
|
|
"nameLocation": "4506:6:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26990,
|
|
"src": "4498:14:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 26972,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4498:7:22",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 26975,
|
|
"mutability": "mutable",
|
|
"name": "data",
|
|
"nameLocation": "4535:4:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26990,
|
|
"src": "4522:17:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 26974,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4522:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 26977,
|
|
"mutability": "mutable",
|
|
"name": "value",
|
|
"nameLocation": "4557:5:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26990,
|
|
"src": "4549:13:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 26976,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4549:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "4488:80:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 26981,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 26980,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nameLocation": "-1:-1:-1",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 26990,
|
|
"src": "4587:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 26979,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4587:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "4586:14:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "nonpayable",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 27034,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "4960:446:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 27033,
|
|
"nodeType": "Block",
|
|
"src": "5139:267:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 27011,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 27007,
|
|
"name": "this",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": -28,
|
|
"src": "5165:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_Address_$27210",
|
|
"typeString": "library Address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_Address_$27210",
|
|
"typeString": "library Address"
|
|
}
|
|
],
|
|
"id": 27006,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "5157:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": {
|
|
"id": 27005,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5157:7:22",
|
|
"typeDescriptions": {}
|
|
}
|
|
},
|
|
"id": 27008,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "5157:13:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 27009,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberLocation": "5171:7:22",
|
|
"memberName": "balance",
|
|
"nodeType": "MemberAccess",
|
|
"src": "5157:21:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">=",
|
|
"rightExpression": {
|
|
"id": 27010,
|
|
"name": "value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26997,
|
|
"src": "5182:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "5157:30:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
{
|
|
"hexValue": "416464726573733a20696e73756666696369656e742062616c616e636520666f722063616c6c",
|
|
"id": 27012,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5189:40:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_565f1a77334fc4792800921178c71e4521acffab18ff9e7885b49377ee80ab4c",
|
|
"typeString": "literal_string \"Address: insufficient balance for call\""
|
|
},
|
|
"value": "Address: insufficient balance for call"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_stringliteral_565f1a77334fc4792800921178c71e4521acffab18ff9e7885b49377ee80ab4c",
|
|
"typeString": "literal_string \"Address: insufficient balance for call\""
|
|
}
|
|
],
|
|
"id": 27004,
|
|
"name": "require",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
-18,
|
|
-18
|
|
],
|
|
"referencedDeclaration": -18,
|
|
"src": "5149:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
|
|
"typeString": "function (bool,string memory) pure"
|
|
}
|
|
},
|
|
"id": 27013,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "5149:81:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 27014,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "5149:81:22"
|
|
},
|
|
{
|
|
"assignments": [
|
|
27016,
|
|
27018
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 27016,
|
|
"mutability": "mutable",
|
|
"name": "success",
|
|
"nameLocation": "5246:7:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27033,
|
|
"src": "5241:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 27015,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5241:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27018,
|
|
"mutability": "mutable",
|
|
"name": "returndata",
|
|
"nameLocation": "5268:10:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27033,
|
|
"src": "5255:23:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27017,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5255:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 27025,
|
|
"initialValue": {
|
|
"arguments": [
|
|
{
|
|
"id": 27023,
|
|
"name": "data",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26995,
|
|
"src": "5308:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
],
|
|
"expression": {
|
|
"id": 27019,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26993,
|
|
"src": "5282:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 27020,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberLocation": "5289:4:22",
|
|
"memberName": "call",
|
|
"nodeType": "MemberAccess",
|
|
"src": "5282:11:22",
|
|
"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": 27022,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"names": [
|
|
"value"
|
|
],
|
|
"nodeType": "FunctionCallOptions",
|
|
"options": [
|
|
{
|
|
"id": 27021,
|
|
"name": "value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26997,
|
|
"src": "5301:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"src": "5282:25:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_barecall_payable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$value",
|
|
"typeString": "function (bytes memory) payable returns (bool,bytes memory)"
|
|
}
|
|
},
|
|
"id": 27024,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "5282:31:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
|
|
"typeString": "tuple(bool,bytes memory)"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "5240:73:22"
|
|
},
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 27027,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26993,
|
|
"src": "5357:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"id": 27028,
|
|
"name": "success",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27016,
|
|
"src": "5365:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
{
|
|
"id": 27029,
|
|
"name": "returndata",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27018,
|
|
"src": "5374:10:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
{
|
|
"id": 27030,
|
|
"name": "errorMessage",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26999,
|
|
"src": "5386:12:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
],
|
|
"id": 27026,
|
|
"name": "verifyCallResultFromTarget",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27165,
|
|
"src": "5330:26:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_address_$_t_bool_$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
|
|
"typeString": "function (address,bool,bytes memory,string memory) view returns (bytes memory)"
|
|
}
|
|
},
|
|
"id": 27031,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "5330:69:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 27003,
|
|
"id": 27032,
|
|
"nodeType": "Return",
|
|
"src": "5323:76:22"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 26991,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "4718:237:22",
|
|
"text": " @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but\n with `errorMessage` as a fallback revert reason when `target` reverts.\n _Available since v3.1._"
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "functionCallWithValue",
|
|
"nameLocation": "4969:21:22",
|
|
"parameters": {
|
|
"id": 27000,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 26993,
|
|
"mutability": "mutable",
|
|
"name": "target",
|
|
"nameLocation": "5008:6:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27034,
|
|
"src": "5000:14:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 26992,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5000:7:22",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 26995,
|
|
"mutability": "mutable",
|
|
"name": "data",
|
|
"nameLocation": "5037:4:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27034,
|
|
"src": "5024:17:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 26994,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5024:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 26997,
|
|
"mutability": "mutable",
|
|
"name": "value",
|
|
"nameLocation": "5059:5:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27034,
|
|
"src": "5051:13:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 26996,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5051:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 26999,
|
|
"mutability": "mutable",
|
|
"name": "errorMessage",
|
|
"nameLocation": "5088:12:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27034,
|
|
"src": "5074:26:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string"
|
|
},
|
|
"typeName": {
|
|
"id": 26998,
|
|
"name": "string",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5074:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage_ptr",
|
|
"typeString": "string"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "4990:116:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 27003,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27002,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nameLocation": "-1:-1:-1",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27034,
|
|
"src": "5125:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27001,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5125:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5124:14:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "nonpayable",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 27051,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "5583:197:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 27050,
|
|
"nodeType": "Block",
|
|
"src": "5683:97:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 27045,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27037,
|
|
"src": "5719:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"id": 27046,
|
|
"name": "data",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27039,
|
|
"src": "5727:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
{
|
|
"hexValue": "416464726573733a206c6f772d6c6576656c207374617469632063616c6c206661696c6564",
|
|
"id": 27047,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5733:39:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_90ec82aa826a536a4cbfae44ecfa384680faa9a4b77344bce96aa761ad904df0",
|
|
"typeString": "literal_string \"Address: low-level static call failed\""
|
|
},
|
|
"value": "Address: low-level static call failed"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_stringliteral_90ec82aa826a536a4cbfae44ecfa384680faa9a4b77344bce96aa761ad904df0",
|
|
"typeString": "literal_string \"Address: low-level static call failed\""
|
|
}
|
|
],
|
|
"id": 27044,
|
|
"name": "functionStaticCall",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
27051,
|
|
27080
|
|
],
|
|
"referencedDeclaration": 27080,
|
|
"src": "5700:18:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_address_$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
|
|
"typeString": "function (address,bytes memory,string memory) view returns (bytes memory)"
|
|
}
|
|
},
|
|
"id": 27048,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "5700:73:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 27043,
|
|
"id": 27049,
|
|
"nodeType": "Return",
|
|
"src": "5693:80:22"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 27035,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "5412:166:22",
|
|
"text": " @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n but performing a static call.\n _Available since v3.3._"
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "functionStaticCall",
|
|
"nameLocation": "5592:18:22",
|
|
"parameters": {
|
|
"id": 27040,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27037,
|
|
"mutability": "mutable",
|
|
"name": "target",
|
|
"nameLocation": "5619:6:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27051,
|
|
"src": "5611:14:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 27036,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5611:7:22",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27039,
|
|
"mutability": "mutable",
|
|
"name": "data",
|
|
"nameLocation": "5640:4:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27051,
|
|
"src": "5627:17:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27038,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5627:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5610:35:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 27043,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27042,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nameLocation": "-1:-1:-1",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27051,
|
|
"src": "5669:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27041,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5669:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5668:14:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "view",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 27080,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "5964:326:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 27079,
|
|
"nodeType": "Block",
|
|
"src": "6122:168:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
27064,
|
|
27066
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 27064,
|
|
"mutability": "mutable",
|
|
"name": "success",
|
|
"nameLocation": "6138:7:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27079,
|
|
"src": "6133:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 27063,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6133:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27066,
|
|
"mutability": "mutable",
|
|
"name": "returndata",
|
|
"nameLocation": "6160:10:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27079,
|
|
"src": "6147:23:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27065,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6147:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 27071,
|
|
"initialValue": {
|
|
"arguments": [
|
|
{
|
|
"id": 27069,
|
|
"name": "data",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27056,
|
|
"src": "6192:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
],
|
|
"expression": {
|
|
"id": 27067,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27054,
|
|
"src": "6174:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 27068,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberLocation": "6181:10:22",
|
|
"memberName": "staticcall",
|
|
"nodeType": "MemberAccess",
|
|
"src": "6174:17:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_barestaticcall_view$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$",
|
|
"typeString": "function (bytes memory) view returns (bool,bytes memory)"
|
|
}
|
|
},
|
|
"id": 27070,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "6174:23:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
|
|
"typeString": "tuple(bool,bytes memory)"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "6132:65:22"
|
|
},
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 27073,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27054,
|
|
"src": "6241:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"id": 27074,
|
|
"name": "success",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27064,
|
|
"src": "6249:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
{
|
|
"id": 27075,
|
|
"name": "returndata",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27066,
|
|
"src": "6258:10:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
{
|
|
"id": 27076,
|
|
"name": "errorMessage",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27058,
|
|
"src": "6270:12:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
],
|
|
"id": 27072,
|
|
"name": "verifyCallResultFromTarget",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27165,
|
|
"src": "6214:26:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_address_$_t_bool_$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
|
|
"typeString": "function (address,bool,bytes memory,string memory) view returns (bytes memory)"
|
|
}
|
|
},
|
|
"id": 27077,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "6214:69:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 27062,
|
|
"id": 27078,
|
|
"nodeType": "Return",
|
|
"src": "6207:76:22"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 27052,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "5786:173:22",
|
|
"text": " @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\n but performing a static call.\n _Available since v3.3._"
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "functionStaticCall",
|
|
"nameLocation": "5973:18:22",
|
|
"parameters": {
|
|
"id": 27059,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27054,
|
|
"mutability": "mutable",
|
|
"name": "target",
|
|
"nameLocation": "6009:6:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27080,
|
|
"src": "6001:14:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 27053,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6001:7:22",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27056,
|
|
"mutability": "mutable",
|
|
"name": "data",
|
|
"nameLocation": "6038:4:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27080,
|
|
"src": "6025:17:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27055,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6025:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27058,
|
|
"mutability": "mutable",
|
|
"name": "errorMessage",
|
|
"nameLocation": "6066:12:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27080,
|
|
"src": "6052:26:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string"
|
|
},
|
|
"typeName": {
|
|
"id": 27057,
|
|
"name": "string",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6052:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage_ptr",
|
|
"typeString": "string"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5991:93:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 27062,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27061,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nameLocation": "-1:-1:-1",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27080,
|
|
"src": "6108:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27060,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6108:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "6107:14:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "view",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 27097,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "6469:198:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 27096,
|
|
"nodeType": "Block",
|
|
"src": "6566:101:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 27091,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27083,
|
|
"src": "6604:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"id": 27092,
|
|
"name": "data",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27085,
|
|
"src": "6612:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
{
|
|
"hexValue": "416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564",
|
|
"id": 27093,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "6618:41:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_9fdcd12e4b726339b32a442b0a448365d5d85c96b2d2cff917b4f66c63110398",
|
|
"typeString": "literal_string \"Address: low-level delegate call failed\""
|
|
},
|
|
"value": "Address: low-level delegate call failed"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_stringliteral_9fdcd12e4b726339b32a442b0a448365d5d85c96b2d2cff917b4f66c63110398",
|
|
"typeString": "literal_string \"Address: low-level delegate call failed\""
|
|
}
|
|
],
|
|
"id": 27090,
|
|
"name": "functionDelegateCall",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
27097,
|
|
27126
|
|
],
|
|
"referencedDeclaration": 27126,
|
|
"src": "6583:20:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
|
|
"typeString": "function (address,bytes memory,string memory) returns (bytes memory)"
|
|
}
|
|
},
|
|
"id": 27094,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "6583:77:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 27089,
|
|
"id": 27095,
|
|
"nodeType": "Return",
|
|
"src": "6576:84:22"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 27081,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "6296:168:22",
|
|
"text": " @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n but performing a delegate call.\n _Available since v3.4._"
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "functionDelegateCall",
|
|
"nameLocation": "6478:20:22",
|
|
"parameters": {
|
|
"id": 27086,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27083,
|
|
"mutability": "mutable",
|
|
"name": "target",
|
|
"nameLocation": "6507:6:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27097,
|
|
"src": "6499:14:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 27082,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6499:7:22",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27085,
|
|
"mutability": "mutable",
|
|
"name": "data",
|
|
"nameLocation": "6528:4:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27097,
|
|
"src": "6515:17:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27084,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6515:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "6498:35:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 27089,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27088,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nameLocation": "-1:-1:-1",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27097,
|
|
"src": "6552:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27087,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6552:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "6551:14:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "nonpayable",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 27126,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "6853:325:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 27125,
|
|
"nodeType": "Block",
|
|
"src": "7008:170:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
27110,
|
|
27112
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 27110,
|
|
"mutability": "mutable",
|
|
"name": "success",
|
|
"nameLocation": "7024:7:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27125,
|
|
"src": "7019:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 27109,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "7019:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27112,
|
|
"mutability": "mutable",
|
|
"name": "returndata",
|
|
"nameLocation": "7046:10:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27125,
|
|
"src": "7033:23:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27111,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "7033:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 27117,
|
|
"initialValue": {
|
|
"arguments": [
|
|
{
|
|
"id": 27115,
|
|
"name": "data",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27102,
|
|
"src": "7080:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
],
|
|
"expression": {
|
|
"id": 27113,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27100,
|
|
"src": "7060:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 27114,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberLocation": "7067:12:22",
|
|
"memberName": "delegatecall",
|
|
"nodeType": "MemberAccess",
|
|
"src": "7060:19:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_baredelegatecall_nonpayable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$",
|
|
"typeString": "function (bytes memory) returns (bool,bytes memory)"
|
|
}
|
|
},
|
|
"id": 27116,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "7060:25:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
|
|
"typeString": "tuple(bool,bytes memory)"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "7018:67:22"
|
|
},
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 27119,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27100,
|
|
"src": "7129:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"id": 27120,
|
|
"name": "success",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27110,
|
|
"src": "7137:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
{
|
|
"id": 27121,
|
|
"name": "returndata",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27112,
|
|
"src": "7146:10:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
{
|
|
"id": 27122,
|
|
"name": "errorMessage",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27104,
|
|
"src": "7158:12:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
],
|
|
"id": 27118,
|
|
"name": "verifyCallResultFromTarget",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27165,
|
|
"src": "7102:26:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_address_$_t_bool_$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
|
|
"typeString": "function (address,bool,bytes memory,string memory) view returns (bytes memory)"
|
|
}
|
|
},
|
|
"id": 27123,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "7102:69:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 27108,
|
|
"id": 27124,
|
|
"nodeType": "Return",
|
|
"src": "7095:76:22"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 27098,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "6673:175:22",
|
|
"text": " @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\n but performing a delegate call.\n _Available since v3.4._"
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "functionDelegateCall",
|
|
"nameLocation": "6862:20:22",
|
|
"parameters": {
|
|
"id": 27105,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27100,
|
|
"mutability": "mutable",
|
|
"name": "target",
|
|
"nameLocation": "6900:6:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27126,
|
|
"src": "6892:14:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 27099,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6892:7:22",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27102,
|
|
"mutability": "mutable",
|
|
"name": "data",
|
|
"nameLocation": "6929:4:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27126,
|
|
"src": "6916:17:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27101,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6916:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27104,
|
|
"mutability": "mutable",
|
|
"name": "errorMessage",
|
|
"nameLocation": "6957:12:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27126,
|
|
"src": "6943:26:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string"
|
|
},
|
|
"typeName": {
|
|
"id": 27103,
|
|
"name": "string",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6943:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage_ptr",
|
|
"typeString": "string"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "6882:93:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 27108,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27107,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nameLocation": "-1:-1:-1",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27126,
|
|
"src": "6994:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27106,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6994:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "6993:14:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "nonpayable",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 27165,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "7466:628:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 27164,
|
|
"nodeType": "Block",
|
|
"src": "7660:434:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"condition": {
|
|
"id": 27140,
|
|
"name": "success",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27131,
|
|
"src": "7674:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": {
|
|
"id": 27162,
|
|
"nodeType": "Block",
|
|
"src": "8030:58:22",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 27158,
|
|
"name": "returndata",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27133,
|
|
"src": "8052:10:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
{
|
|
"id": 27159,
|
|
"name": "errorMessage",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27135,
|
|
"src": "8064:12:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
],
|
|
"id": 27157,
|
|
"name": "_revert",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27209,
|
|
"src": "8044:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$__$",
|
|
"typeString": "function (bytes memory,string memory) pure"
|
|
}
|
|
},
|
|
"id": 27160,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "8044:33:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 27161,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "8044:33:22"
|
|
}
|
|
]
|
|
},
|
|
"id": 27163,
|
|
"nodeType": "IfStatement",
|
|
"src": "7670:418:22",
|
|
"trueBody": {
|
|
"id": 27156,
|
|
"nodeType": "Block",
|
|
"src": "7683:341:22",
|
|
"statements": [
|
|
{
|
|
"condition": {
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 27144,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"expression": {
|
|
"id": 27141,
|
|
"name": "returndata",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27133,
|
|
"src": "7701:10:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"id": 27142,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberLocation": "7712:6:22",
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"src": "7701:17:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "==",
|
|
"rightExpression": {
|
|
"hexValue": "30",
|
|
"id": 27143,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "7722:1:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "7701:22:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 27153,
|
|
"nodeType": "IfStatement",
|
|
"src": "7697:286:22",
|
|
"trueBody": {
|
|
"id": 27152,
|
|
"nodeType": "Block",
|
|
"src": "7725:258:22",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"arguments": [
|
|
{
|
|
"id": 27147,
|
|
"name": "target",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27129,
|
|
"src": "7927:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"id": 27146,
|
|
"name": "isContract",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 26898,
|
|
"src": "7916:10:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$",
|
|
"typeString": "function (address) view returns (bool)"
|
|
}
|
|
},
|
|
"id": 27148,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "7916:18:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
{
|
|
"hexValue": "416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374",
|
|
"id": 27149,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "7936:31:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_cc2e4e38850b7c0a3e942cfed89b71c77302df25bcb2ec297a0c4ff9ff6b90ad",
|
|
"typeString": "literal_string \"Address: call to non-contract\""
|
|
},
|
|
"value": "Address: call to non-contract"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_stringliteral_cc2e4e38850b7c0a3e942cfed89b71c77302df25bcb2ec297a0c4ff9ff6b90ad",
|
|
"typeString": "literal_string \"Address: call to non-contract\""
|
|
}
|
|
],
|
|
"id": 27145,
|
|
"name": "require",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
-18,
|
|
-18
|
|
],
|
|
"referencedDeclaration": -18,
|
|
"src": "7908:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
|
|
"typeString": "function (bool,string memory) pure"
|
|
}
|
|
},
|
|
"id": 27150,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "7908:60:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 27151,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "7908:60:22"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
{
|
|
"expression": {
|
|
"id": 27154,
|
|
"name": "returndata",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27133,
|
|
"src": "8003:10:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 27139,
|
|
"id": 27155,
|
|
"nodeType": "Return",
|
|
"src": "7996:17:22"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 27127,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "7184:277:22",
|
|
"text": " @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling\n the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.\n _Available since v4.8._"
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "verifyCallResultFromTarget",
|
|
"nameLocation": "7475:26:22",
|
|
"parameters": {
|
|
"id": 27136,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27129,
|
|
"mutability": "mutable",
|
|
"name": "target",
|
|
"nameLocation": "7519:6:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27165,
|
|
"src": "7511:14:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 27128,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "7511:7:22",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27131,
|
|
"mutability": "mutable",
|
|
"name": "success",
|
|
"nameLocation": "7540:7:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27165,
|
|
"src": "7535:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 27130,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "7535:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27133,
|
|
"mutability": "mutable",
|
|
"name": "returndata",
|
|
"nameLocation": "7570:10:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27165,
|
|
"src": "7557:23:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27132,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "7557:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27135,
|
|
"mutability": "mutable",
|
|
"name": "errorMessage",
|
|
"nameLocation": "7604:12:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27165,
|
|
"src": "7590:26:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string"
|
|
},
|
|
"typeName": {
|
|
"id": 27134,
|
|
"name": "string",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "7590:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage_ptr",
|
|
"typeString": "string"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "7501:121:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 27139,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27138,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nameLocation": "-1:-1:-1",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27165,
|
|
"src": "7646:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27137,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "7646:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "7645:14:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "view",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 27189,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "8315:295:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 27188,
|
|
"nodeType": "Block",
|
|
"src": "8475:135:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"condition": {
|
|
"id": 27177,
|
|
"name": "success",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27168,
|
|
"src": "8489:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": {
|
|
"id": 27186,
|
|
"nodeType": "Block",
|
|
"src": "8546:58:22",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 27182,
|
|
"name": "returndata",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27170,
|
|
"src": "8568:10:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
{
|
|
"id": 27183,
|
|
"name": "errorMessage",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27172,
|
|
"src": "8580:12:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
],
|
|
"id": 27181,
|
|
"name": "_revert",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27209,
|
|
"src": "8560:7:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$__$",
|
|
"typeString": "function (bytes memory,string memory) pure"
|
|
}
|
|
},
|
|
"id": 27184,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "8560:33:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 27185,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "8560:33:22"
|
|
}
|
|
]
|
|
},
|
|
"id": 27187,
|
|
"nodeType": "IfStatement",
|
|
"src": "8485:119:22",
|
|
"trueBody": {
|
|
"id": 27180,
|
|
"nodeType": "Block",
|
|
"src": "8498:42:22",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"id": 27178,
|
|
"name": "returndata",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27170,
|
|
"src": "8519:10:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 27176,
|
|
"id": 27179,
|
|
"nodeType": "Return",
|
|
"src": "8512:17:22"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 27166,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "8100:210:22",
|
|
"text": " @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the\n revert reason or using the provided one.\n _Available since v4.3._"
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "verifyCallResult",
|
|
"nameLocation": "8324:16:22",
|
|
"parameters": {
|
|
"id": 27173,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27168,
|
|
"mutability": "mutable",
|
|
"name": "success",
|
|
"nameLocation": "8355:7:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27189,
|
|
"src": "8350:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 27167,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "8350:4:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27170,
|
|
"mutability": "mutable",
|
|
"name": "returndata",
|
|
"nameLocation": "8385:10:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27189,
|
|
"src": "8372:23:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27169,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "8372:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27172,
|
|
"mutability": "mutable",
|
|
"name": "errorMessage",
|
|
"nameLocation": "8419:12:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27189,
|
|
"src": "8405:26:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string"
|
|
},
|
|
"typeName": {
|
|
"id": 27171,
|
|
"name": "string",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "8405:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage_ptr",
|
|
"typeString": "string"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "8340:97:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 27176,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27175,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nameLocation": "-1:-1:-1",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27189,
|
|
"src": "8461:12:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27174,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "8461:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "8460:14:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "pure",
|
|
"virtual": false,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"id": 27209,
|
|
"nodeType": "FunctionDefinition",
|
|
"src": "8616:540:22",
|
|
"nodes": [],
|
|
"body": {
|
|
"id": 27208,
|
|
"nodeType": "Block",
|
|
"src": "8699:457:22",
|
|
"nodes": [],
|
|
"statements": [
|
|
{
|
|
"condition": {
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 27199,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"expression": {
|
|
"id": 27196,
|
|
"name": "returndata",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27191,
|
|
"src": "8775:10:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes memory"
|
|
}
|
|
},
|
|
"id": 27197,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberLocation": "8786:6:22",
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"src": "8775:17:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"hexValue": "30",
|
|
"id": 27198,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "8795:1:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "8775:21:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": {
|
|
"id": 27206,
|
|
"nodeType": "Block",
|
|
"src": "9105:45:22",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"id": 27203,
|
|
"name": "errorMessage",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 27193,
|
|
"src": "9126:12:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string memory"
|
|
}
|
|
],
|
|
"id": 27202,
|
|
"name": "revert",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
-19,
|
|
-19
|
|
],
|
|
"referencedDeclaration": -19,
|
|
"src": "9119:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_revert_pure$_t_string_memory_ptr_$returns$__$",
|
|
"typeString": "function (string memory) pure"
|
|
}
|
|
},
|
|
"id": 27204,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"nameLocations": [],
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "9119:20:22",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 27205,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "9119:20:22"
|
|
}
|
|
]
|
|
},
|
|
"id": 27207,
|
|
"nodeType": "IfStatement",
|
|
"src": "8771:379:22",
|
|
"trueBody": {
|
|
"id": 27201,
|
|
"nodeType": "Block",
|
|
"src": "8798:301:22",
|
|
"statements": [
|
|
{
|
|
"AST": {
|
|
"nodeType": "YulBlock",
|
|
"src": "8956:133:22",
|
|
"statements": [
|
|
{
|
|
"nodeType": "YulVariableDeclaration",
|
|
"src": "8974:40:22",
|
|
"value": {
|
|
"arguments": [
|
|
{
|
|
"name": "returndata",
|
|
"nodeType": "YulIdentifier",
|
|
"src": "9003:10:22"
|
|
}
|
|
],
|
|
"functionName": {
|
|
"name": "mload",
|
|
"nodeType": "YulIdentifier",
|
|
"src": "8997:5:22"
|
|
},
|
|
"nodeType": "YulFunctionCall",
|
|
"src": "8997:17:22"
|
|
},
|
|
"variables": [
|
|
{
|
|
"name": "returndata_size",
|
|
"nodeType": "YulTypedName",
|
|
"src": "8978:15:22",
|
|
"type": ""
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"expression": {
|
|
"arguments": [
|
|
{
|
|
"arguments": [
|
|
{
|
|
"kind": "number",
|
|
"nodeType": "YulLiteral",
|
|
"src": "9042:2:22",
|
|
"type": "",
|
|
"value": "32"
|
|
},
|
|
{
|
|
"name": "returndata",
|
|
"nodeType": "YulIdentifier",
|
|
"src": "9046:10:22"
|
|
}
|
|
],
|
|
"functionName": {
|
|
"name": "add",
|
|
"nodeType": "YulIdentifier",
|
|
"src": "9038:3:22"
|
|
},
|
|
"nodeType": "YulFunctionCall",
|
|
"src": "9038:19:22"
|
|
},
|
|
{
|
|
"name": "returndata_size",
|
|
"nodeType": "YulIdentifier",
|
|
"src": "9059:15:22"
|
|
}
|
|
],
|
|
"functionName": {
|
|
"name": "revert",
|
|
"nodeType": "YulIdentifier",
|
|
"src": "9031:6:22"
|
|
},
|
|
"nodeType": "YulFunctionCall",
|
|
"src": "9031:44:22"
|
|
},
|
|
"nodeType": "YulExpressionStatement",
|
|
"src": "9031:44:22"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "@solidity memory-safe-assembly",
|
|
"evmVersion": "london",
|
|
"externalReferences": [
|
|
{
|
|
"declaration": 27191,
|
|
"isOffset": false,
|
|
"isSlot": false,
|
|
"src": "9003:10:22",
|
|
"valueSize": 1
|
|
},
|
|
{
|
|
"declaration": 27191,
|
|
"isOffset": false,
|
|
"isSlot": false,
|
|
"src": "9046:10:22",
|
|
"valueSize": 1
|
|
}
|
|
],
|
|
"id": 27200,
|
|
"nodeType": "InlineAssembly",
|
|
"src": "8947:142:22"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "_revert",
|
|
"nameLocation": "8625:7:22",
|
|
"parameters": {
|
|
"id": 27194,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 27191,
|
|
"mutability": "mutable",
|
|
"name": "returndata",
|
|
"nameLocation": "8646:10:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27209,
|
|
"src": "8633:23:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_memory_ptr",
|
|
"typeString": "bytes"
|
|
},
|
|
"typeName": {
|
|
"id": 27190,
|
|
"name": "bytes",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "8633:5:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes_storage_ptr",
|
|
"typeString": "bytes"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 27193,
|
|
"mutability": "mutable",
|
|
"name": "errorMessage",
|
|
"nameLocation": "8672:12:22",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 27209,
|
|
"src": "8658:26:22",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_memory_ptr",
|
|
"typeString": "string"
|
|
},
|
|
"typeName": {
|
|
"id": 27192,
|
|
"name": "string",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "8658:6:22",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage_ptr",
|
|
"typeString": "string"
|
|
}
|
|
},
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "8632:53:22"
|
|
},
|
|
"returnParameters": {
|
|
"id": 27195,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "8699:0:22"
|
|
},
|
|
"scope": 27210,
|
|
"stateMutability": "pure",
|
|
"virtual": false,
|
|
"visibility": "private"
|
|
}
|
|
],
|
|
"abstract": false,
|
|
"baseContracts": [],
|
|
"canonicalName": "Address",
|
|
"contractDependencies": [],
|
|
"contractKind": "library",
|
|
"documentation": {
|
|
"id": 26883,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "126:67:22",
|
|
"text": " @dev Collection of functions related to the address type"
|
|
},
|
|
"fullyImplemented": true,
|
|
"linearizedBaseContracts": [
|
|
27210
|
|
],
|
|
"name": "Address",
|
|
"nameLocation": "202:7:22",
|
|
"scope": 27211,
|
|
"usedErrors": []
|
|
}
|
|
],
|
|
"license": "MIT"
|
|
},
|
|
"id": 22
|
|
} |