Yul AST output on the CLI and in Standard JSON

This commit is contained in:
GiokaMarkella
2023-05-26 12:35:31 +02:00
committed by Kamil Śliwak
parent bb16f61e1c
commit 28a1abf89a
62 changed files with 4542 additions and 43 deletions
@@ -39,16 +39,19 @@
{
"AST":
{
"nativeSrc": "61:129:1",
"nodeType": "YulBlock",
"src": "61:129:1",
"statements":
[
{
"nativeSrc": "75:10:1",
"nodeType": "YulVariableDeclaration",
"src": "75:10:1",
"value":
{
"kind": "number",
"nativeSrc": "84:1:1",
"nodeType": "YulLiteral",
"src": "84:1:1",
"type": "",
@@ -58,6 +61,7 @@
[
{
"name": "v",
"nativeSrc": "79:1:1",
"nodeType": "YulTypedName",
"src": "79:1:1",
"type": ""
@@ -70,16 +74,19 @@
{
"body":
{
"nativeSrc": "139:10:1",
"nodeType": "YulBlock",
"src": "139:10:1",
"statements":
[
{
"nativeSrc": "141:6:1",
"nodeType": "YulAssignment",
"src": "141:6:1",
"value":
{
"kind": "number",
"nativeSrc": "146:1:1",
"nodeType": "YulLiteral",
"src": "146:1:1",
"type": "",
@@ -89,6 +96,7 @@
[
{
"name": "v",
"nativeSrc": "141:1:1",
"nodeType": "YulIdentifier",
"src": "141:1:1"
}
@@ -96,11 +104,13 @@
}
]
},
"nativeSrc": "132:17:1",
"nodeType": "YulCase",
"src": "132:17:1",
"value":
{
"kind": "number",
"nativeSrc": "137:1:1",
"nodeType": "YulLiteral",
"src": "137:1:1",
"type": "",
@@ -110,16 +120,19 @@
{
"body":
{
"nativeSrc": "170:10:1",
"nodeType": "YulBlock",
"src": "170:10:1",
"statements":
[
{
"nativeSrc": "172:6:1",
"nodeType": "YulAssignment",
"src": "172:6:1",
"value":
{
"kind": "number",
"nativeSrc": "177:1:1",
"nodeType": "YulLiteral",
"src": "177:1:1",
"type": "",
@@ -129,6 +142,7 @@
[
{
"name": "v",
"nativeSrc": "172:1:1",
"nodeType": "YulIdentifier",
"src": "172:1:1"
}
@@ -136,6 +150,7 @@
}
]
},
"nativeSrc": "162:18:1",
"nodeType": "YulCase",
"src": "162:18:1",
"value": "default"
@@ -147,12 +162,15 @@
"functionName":
{
"name": "calldatasize",
"nativeSrc": "105:12:1",
"nodeType": "YulIdentifier",
"src": "105:12:1"
},
"nativeSrc": "105:14:1",
"nodeType": "YulFunctionCall",
"src": "105:14:1"
},
"nativeSrc": "98:82:1",
"nodeType": "YulSwitch",
"src": "98:82:1"
}