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.
ChocoPy/pa3-tests/core/stmt_for_str_eval.py.ast.typed

142 lines
3.3 KiB

{
"kind" : "Program",
"location" : [ 1, 1, 7, 1 ],
"declarations" : [ {
"kind" : "VarDef",
"location" : [ 1, 1, 1, 10 ],
"var" : {
"kind" : "TypedVar",
"location" : [ 1, 1, 1, 5 ],
"identifier" : {
"kind" : "Identifier",
"location" : [ 1, 1, 1, 1 ],
"name" : "x"
},
"type" : {
"kind" : "ClassType",
"location" : [ 1, 3, 1, 5 ],
"className" : "str"
}
},
"value" : {
"kind" : "StringLiteral",
"location" : [ 1, 9, 1, 10 ],
"inferredType" : {
"kind" : "ClassValueType",
"className" : "str"
},
"value" : ""
}
}, {
"kind" : "VarDef",
"location" : [ 2, 1, 2, 13 ],
"var" : {
"kind" : "TypedVar",
"location" : [ 2, 1, 2, 5 ],
"identifier" : {
"kind" : "Identifier",
"location" : [ 2, 1, 2, 1 ],
"name" : "z"
},
"type" : {
"kind" : "ClassType",
"location" : [ 2, 3, 2, 5 ],
"className" : "str"
}
},
"value" : {
"kind" : "StringLiteral",
"location" : [ 2, 9, 2, 13 ],
"inferredType" : {
"kind" : "ClassValueType",
"className" : "str"
},
"value" : "abc"
}
} ],
"statements" : [ {
"kind" : "ForStmt",
"location" : [ 4, 1, 7, 1 ],
"identifier" : {
"kind" : "Identifier",
"location" : [ 4, 5, 4, 5 ],
"inferredType" : {
"kind" : "ClassValueType",
"className" : "str"
},
"name" : "x"
},
"iterable" : {
"kind" : "Identifier",
"location" : [ 4, 10, 4, 10 ],
"inferredType" : {
"kind" : "ClassValueType",
"className" : "str"
},
"name" : "z"
},
"body" : [ {
"kind" : "AssignStmt",
"location" : [ 5, 5, 5, 24 ],
"targets" : [ {
"kind" : "Identifier",
"location" : [ 5, 5, 5, 5 ],
"inferredType" : {
"kind" : "ClassValueType",
"className" : "str"
},
"name" : "z"
} ],
"value" : {
"kind" : "StringLiteral",
"location" : [ 5, 9, 5, 24 ],
"inferredType" : {
"kind" : "ClassValueType",
"className" : "str"
},
"value" : "doesn't matter"
}
}, {
"kind" : "ExprStmt",
"location" : [ 6, 5, 6, 12 ],
"expr" : {
"kind" : "CallExpr",
"location" : [ 6, 5, 6, 12 ],
"inferredType" : {
"kind" : "ClassValueType",
"className" : "<None>"
},
"function" : {
"kind" : "Identifier",
"location" : [ 6, 5, 6, 9 ],
"inferredType" : {
"kind" : "FuncType",
"parameters" : [ {
"kind" : "ClassValueType",
"className" : "object"
} ],
"returnType" : {
"kind" : "ClassValueType",
"className" : "<None>"
}
},
"name" : "print"
},
"args" : [ {
"kind" : "Identifier",
"location" : [ 6, 11, 6, 11 ],
"inferredType" : {
"kind" : "ClassValueType",
"className" : "str"
},
"name" : "x"
} ]
}
} ]
} ],
"errors" : {
"errors" : [ ],
"kind" : "Errors",
"location" : [ 0, 0, 0, 0 ]
}
}