solidity/test/libsolidity/ASTJSON/used_errors_parseOnly.json

173 lines
4.0 KiB
JSON
Raw Normal View History

2021-04-15 07:59:59 +00:00
{
"absolutePath": "a",
"id": 20,
"nodeType": "SourceUnit",
"nodes":
[
{
"id": 2,
"name": "X",
"nameLocation": "6:1:1",
"nodeType": "ErrorDefinition",
"parameters":
{
"id": 1,
"nodeType": "ParameterList",
"parameters": [],
"src": "7:2:1"
},
"src": "0:10:1"
},
{
"body":
{
"id": 8,
"nodeType": "Block",
2022-02-17 12:38:29 +00:00
"src": "29:15:1",
2021-04-15 07:59:59 +00:00
"statements":
[
{
"errorCall":
{
"arguments": [],
"expression":
{
"id": 5,
"name": "X",
"nodeType": "Identifier",
"overloadedDeclarations": [],
2022-02-17 12:38:29 +00:00
"src": "38:1:1",
2021-04-15 07:59:59 +00:00
"typeDescriptions": {}
},
"id": 6,
"names": [],
"nodeType": "FunctionCall",
2022-02-17 12:38:29 +00:00
"src": "38:3:1",
2021-04-15 07:59:59 +00:00
"tryCall": false,
"typeDescriptions": {}
},
"id": 7,
"nodeType": "RevertStatement",
2022-02-17 12:38:29 +00:00
"src": "31:10:1"
2021-04-15 07:59:59 +00:00
}
]
},
"id": 9,
"implemented": true,
"kind": "freeFunction",
"modifiers": [],
"name": "f",
"nameLocation": "20:1:1",
"nodeType": "FunctionDefinition",
"parameters":
{
"id": 3,
"nodeType": "ParameterList",
"parameters": [],
"src": "21:2:1"
},
"returnParameters":
{
"id": 4,
"nodeType": "ParameterList",
"parameters": [],
2022-02-17 12:38:29 +00:00
"src": "29:0:1"
2021-04-15 07:59:59 +00:00
},
2022-02-17 12:38:29 +00:00
"src": "11:33:1",
"stateMutability": "pure",
2021-04-15 07:59:59 +00:00
"virtual": false,
"visibility": "internal"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "contract",
"id": 19,
"name": "C",
2022-02-17 12:38:29 +00:00
"nameLocation": "54:1:1",
2021-04-15 07:59:59 +00:00
"nodeType": "ContractDefinition",
"nodes":
[
{
"id": 11,
"name": "T",
2022-02-17 12:38:29 +00:00
"nameLocation": "68:1:1",
2021-04-15 07:59:59 +00:00
"nodeType": "ErrorDefinition",
"parameters":
{
"id": 10,
"nodeType": "ParameterList",
"parameters": [],
2022-02-17 12:38:29 +00:00
"src": "69:2:1"
2021-04-15 07:59:59 +00:00
},
2022-02-17 12:38:29 +00:00
"src": "62:10:1"
2021-04-15 07:59:59 +00:00
},
{
"body":
{
"id": 17,
"nodeType": "Block",
2022-02-17 12:38:29 +00:00
"src": "97:8:1",
2021-04-15 07:59:59 +00:00
"statements":
[
{
"expression":
{
"arguments": [],
"expression":
{
"id": 14,
"name": "f",
"nodeType": "Identifier",
"overloadedDeclarations": [],
2022-02-17 12:38:29 +00:00
"src": "99:1:1",
2021-04-15 07:59:59 +00:00
"typeDescriptions": {}
},
"id": 15,
"names": [],
"nodeType": "FunctionCall",
2022-02-17 12:38:29 +00:00
"src": "99:3:1",
2021-04-15 07:59:59 +00:00
"tryCall": false,
"typeDescriptions": {}
},
"id": 16,
"nodeType": "ExpressionStatement",
2022-02-17 12:38:29 +00:00
"src": "99:3:1"
2021-04-15 07:59:59 +00:00
}
]
},
"id": 18,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "h",
2022-02-17 12:38:29 +00:00
"nameLocation": "86:1:1",
2021-04-15 07:59:59 +00:00
"nodeType": "FunctionDefinition",
"parameters":
{
"id": 12,
"nodeType": "ParameterList",
"parameters": [],
2022-02-17 12:38:29 +00:00
"src": "87:2:1"
2021-04-15 07:59:59 +00:00
},
"returnParameters":
{
"id": 13,
"nodeType": "ParameterList",
"parameters": [],
2022-02-17 12:38:29 +00:00
"src": "97:0:1"
2021-04-15 07:59:59 +00:00
},
2022-02-17 12:38:29 +00:00
"src": "77:28:1",
"stateMutability": "nonpayable",
2021-04-15 07:59:59 +00:00
"virtual": false,
"visibility": "public"
}
],
2022-02-17 12:38:29 +00:00
"src": "45:62:1",
2021-04-15 07:59:59 +00:00
"usedErrors": []
}
],
2022-02-17 12:38:29 +00:00
"src": "0:108:1"
2021-04-15 07:59:59 +00:00
}