47 lines
1.5 KiB
JSON
47 lines
1.5 KiB
JSON
|
|
{
|
||
|
|
"type": "Program",
|
||
|
|
"statements": [
|
||
|
|
{
|
||
|
|
"DependStatement": {
|
||
|
|
"type": "DependStatement",
|
||
|
|
"file_path": "tests/math.pla"
|
||
|
|
}
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"FunctionStatement": {
|
||
|
|
"type": "FunctionStatement",
|
||
|
|
"name": {
|
||
|
|
"type": "IdentifierLiteral",
|
||
|
|
"value": "main"
|
||
|
|
},
|
||
|
|
"return_type": "Int",
|
||
|
|
"parameters": [],
|
||
|
|
"body": {
|
||
|
|
"type": "BlockStatement",
|
||
|
|
"statements": [
|
||
|
|
{
|
||
|
|
"type": "ReturnStatement",
|
||
|
|
"return_value": {
|
||
|
|
"type": "CallExpression",
|
||
|
|
"function": {
|
||
|
|
"type": "IdentifierLiteral",
|
||
|
|
"value": "add"
|
||
|
|
},
|
||
|
|
"arguments": [
|
||
|
|
{
|
||
|
|
"type": "IntegerLiteral",
|
||
|
|
"value": 1
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"type": "IntegerLiteral",
|
||
|
|
"value": 2
|
||
|
|
}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|
||
|
|
]
|
||
|
|
}
|