You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
64 lines
1.4 KiB
64 lines
1.4 KiB
{
|
|
"kind" : "Program",
|
|
"location" : [ 1, 1, 5, 1 ],
|
|
"declarations" : [ {
|
|
"kind" : "VarDef",
|
|
"location" : [ 1, 1, 1, 15 ],
|
|
"var" : {
|
|
"kind" : "TypedVar",
|
|
"location" : [ 1, 1, 1, 5 ],
|
|
"identifier" : {
|
|
"kind" : "Identifier",
|
|
"location" : [ 1, 1, 1, 1 ],
|
|
"name" : "s"
|
|
},
|
|
"type" : {
|
|
"kind" : "ClassType",
|
|
"location" : [ 1, 3, 1, 5 ],
|
|
"className" : "str"
|
|
}
|
|
},
|
|
"value" : {
|
|
"kind" : "StringLiteral",
|
|
"location" : [ 1, 9, 1, 15 ],
|
|
"value" : "Hello"
|
|
}
|
|
} ],
|
|
"statements" : [ {
|
|
"kind" : "ForStmt",
|
|
"location" : [ 3, 1, 5, 1 ],
|
|
"identifier" : {
|
|
"kind" : "Identifier",
|
|
"location" : [ 3, 5, 3, 5 ],
|
|
"name" : "s"
|
|
},
|
|
"iterable" : {
|
|
"kind" : "Identifier",
|
|
"location" : [ 3, 10, 3, 10 ],
|
|
"name" : "s"
|
|
},
|
|
"body" : [ {
|
|
"kind" : "ExprStmt",
|
|
"location" : [ 4, 5, 4, 8 ],
|
|
"expr" : {
|
|
"kind" : "IndexExpr",
|
|
"location" : [ 4, 5, 4, 8 ],
|
|
"list" : {
|
|
"kind" : "Identifier",
|
|
"location" : [ 4, 5, 4, 5 ],
|
|
"name" : "s"
|
|
},
|
|
"index" : {
|
|
"kind" : "IntegerLiteral",
|
|
"location" : [ 4, 7, 4, 7 ],
|
|
"value" : 0
|
|
}
|
|
}
|
|
} ]
|
|
} ],
|
|
"errors" : {
|
|
"errors" : [ ],
|
|
"kind" : "Errors",
|
|
"location" : [ 0, 0, 0, 0 ]
|
|
}
|
|
} |