leo/parser/tests/serialization/expected_leo_ast.json

95 lines
3.1 KiB
JSON
Raw Normal View History

{
2021-03-07 17:27:42 +03:00
"name": "",
2020-08-03 06:56:22 +03:00
"expected_input": [],
"import_statements": [],
"imports": {},
"circuits": {},
"global_consts": {},
"functions": {
"main": {
2021-03-07 17:27:42 +03:00
"annotations": [],
"identifier": "{\"name\":\"main\",\"span\":\"{\\\"line_start\\\":1,\\\"line_stop\\\":1,\\\"col_start\\\":10,\\\"col_stop\\\":14,\\\"path\\\":\\\"C:\\\\\\\\Users\\\\\\\\jonat\\\\\\\\AppData\\\\\\\\Roaming\\\\\\\\work\\\\\\\\tester\\\\\\\\src/main.leo\\\",\\\"content\\\":\\\"function main() -> u8 {\\\"}\"}",
2020-08-03 06:56:22 +03:00
"input": [],
"output": {
"IntegerType": "U8"
},
2021-03-07 17:27:42 +03:00
"block": {
"statements": [
{
2020-12-16 23:43:16 +03:00
"Return": {
"expression": {
2020-12-16 22:21:57 +03:00
"Binary": {
"left": {
"Value": {
"Integer": [
"U8",
2020-12-16 22:21:57 +03:00
"1",
{
2021-03-07 17:27:42 +03:00
"line_start": 2,
"line_stop": 2,
"col_start": 12,
"col_stop": 15,
"path": "C:\\Users\\jonat\\AppData\\Roaming\\work\\tester\\src/main.leo",
"content": " return 1u8 + 1u8;"
2020-12-16 22:21:57 +03:00
}
]
}
},
2020-12-16 22:21:57 +03:00
"right": {
"Value": {
"Integer": [
"U8",
2020-12-16 22:21:57 +03:00
"1",
{
2021-03-07 17:27:42 +03:00
"line_start": 2,
"line_stop": 2,
"col_start": 18,
"col_stop": 21,
"path": "C:\\Users\\jonat\\AppData\\Roaming\\work\\tester\\src/main.leo",
"content": " return 1u8 + 1u8;"
2020-12-16 22:21:57 +03:00
}
]
}
},
2021-03-07 17:27:42 +03:00
"op": "Add",
2020-12-16 22:21:57 +03:00
"span": {
2021-03-07 17:27:42 +03:00
"line_start": 2,
"line_stop": 2,
"col_start": 12,
"col_stop": 21,
"path": "C:\\Users\\jonat\\AppData\\Roaming\\work\\tester\\src/main.leo",
"content": " return 1u8 + 1u8;"
}
2020-12-16 22:21:57 +03:00
}
},
2021-03-07 17:27:42 +03:00
"span": {
"line_start": 2,
"line_stop": 2,
"col_start": 5,
"col_stop": 21,
"path": "C:\\Users\\jonat\\AppData\\Roaming\\work\\tester\\src/main.leo",
"content": " return 1u8 + 1u8;"
}
2020-12-16 23:43:16 +03:00
}
}
2020-12-16 23:43:16 +03:00
],
2021-03-07 17:27:42 +03:00
"span": {
"line_start": 1,
"line_stop": 3,
"col_start": 23,
2021-03-07 17:27:42 +03:00
"col_stop": 2,
"path": "C:\\Users\\jonat\\AppData\\Roaming\\work\\tester\\src/main.leo",
"content": "function main() -> u8 {\n ...\n}"
2020-12-16 23:43:16 +03:00
}
},
"span": {
2021-03-07 17:27:42 +03:00
"line_start": 1,
"line_stop": 3,
"col_start": 1,
"col_stop": 2,
"path": "C:\\Users\\jonat\\AppData\\Roaming\\work\\tester\\src/main.leo",
"content": "function main() -> u8 {\n ...\n}"
}
}
2021-03-07 17:27:42 +03:00
}
}