Fix ICE when requesting --combined-json outputs other than AST with --stop-after parsing

This commit is contained in:
Kamil Śliwak
2023-08-21 17:50:41 +02:00
parent b17757ea17
commit 36429e397c
4 changed files with 66 additions and 5 deletions
@@ -0,0 +1 @@
--pretty-json --json-indent 4 --stop-after parsing --combined-json abi,asm,ast,bin,bin-runtime,devdoc,function-debug,function-debug-runtime,generated-sources,generated-sources-runtime,hashes,metadata,opcodes,srcmap,srcmap-runtime,storage-layout,userdoc
@@ -0,0 +1,4 @@
// SPDX-License-Identifier: GPL-3.0
pragma solidity *;
contract C {}
@@ -0,0 +1,53 @@
{
"contracts":
{
"combined_json_stop_after_parsing/input.sol:C": {}
},
"sourceList":
[
"combined_json_stop_after_parsing/input.sol"
],
"sources":
{
"combined_json_stop_after_parsing/input.sol":
{
"AST":
{
"absolutePath": "combined_json_stop_after_parsing/input.sol",
"id": 3,
"license": "GPL-3.0",
"nodeType": "SourceUnit",
"nodes":
[
{
"id": 1,
"literals":
[
"solidity",
"*"
],
"nodeType": "PragmaDirective",
"src": "36:18:0"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "contract",
"id": 2,
"name": "C",
"nameLocation": "65:1:0",
"nodeType": "ContractDefinition",
"nodes": [],
"src": "56:13:0",
"usedErrors": [],
"usedEvents": []
}
],
"src": "36:34:0"
},
"id": 0
}
},
"version": "<VERSION REMOVED>"
}