{ "kind" : "Program", "location" : [ 2, 1, 110, 11 ], "declarations" : [ { "kind" : "ClassDef", "location" : [ 2, 1, 10, 16 ], "name" : { "kind" : "Identifier", "location" : [ 2, 7, 2, 13 ], "name" : "A_CLASS" }, "superClass" : { "kind" : "Identifier", "location" : [ 2, 15, 2, 20 ], "name" : "object" }, "declarations" : [ { "kind" : "VarDef", "location" : [ 3, 5, 3, 21 ], "var" : { "kind" : "TypedVar", "location" : [ 3, 5, 3, 17 ], "identifier" : { "kind" : "Identifier", "location" : [ 3, 5, 3, 13 ], "name" : "a_class_i" }, "type" : { "kind" : "ClassType", "location" : [ 3, 15, 3, 17 ], "className" : "int" } }, "value" : { "kind" : "IntegerLiteral", "location" : [ 3, 21, 3, 21 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 } }, { "kind" : "VarDef", "location" : [ 4, 5, 4, 11 ], "var" : { "kind" : "TypedVar", "location" : [ 4, 5, 4, 9 ], "identifier" : { "kind" : "Identifier", "location" : [ 4, 5, 4, 5 ], "name" : "x" }, "type" : { "kind" : "ClassType", "location" : [ 4, 7, 4, 9 ], "className" : "int" } }, "value" : { "kind" : "IntegerLiteral", "location" : [ 4, 11, 4, 11 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 } }, { "kind" : "FuncDef", "location" : [ 5, 5, 6, 18 ], "name" : { "kind" : "Identifier", "location" : [ 5, 9, 5, 16 ], "name" : "__init__" }, "params" : [ { "kind" : "TypedVar", "location" : [ 5, 18, 5, 31 ], "identifier" : { "kind" : "Identifier", "location" : [ 5, 18, 5, 21 ], "name" : "self" }, "type" : { "kind" : "ClassType", "location" : [ 5, 23, 5, 31 ], "className" : "A_CLASS" } } ], "returnType" : { "kind" : "ClassType", "location" : [ 5, 33, 5, 33 ], "className" : "" }, "declarations" : [ ], "statements" : [ { "kind" : "AssignStmt", "location" : [ 6, 9, 6, 18 ], "targets" : [ { "kind" : "MemberExpr", "location" : [ 6, 9, 6, 14 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "object" : { "kind" : "Identifier", "location" : [ 6, 9, 6, 12 ], "inferredType" : { "kind" : "ClassValueType", "className" : "A_CLASS" }, "name" : "self" }, "member" : { "kind" : "Identifier", "location" : [ 6, 14, 6, 14 ], "name" : "x" } } ], "value" : { "kind" : "IntegerLiteral", "location" : [ 6, 18, 6, 18 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 } } ] }, { "kind" : "FuncDef", "location" : [ 8, 5, 10, 16 ], "name" : { "kind" : "Identifier", "location" : [ 8, 9, 8, 11 ], "name" : "add" }, "params" : [ { "kind" : "TypedVar", "location" : [ 8, 13, 8, 26 ], "identifier" : { "kind" : "Identifier", "location" : [ 8, 13, 8, 16 ], "name" : "self" }, "type" : { "kind" : "ClassType", "location" : [ 8, 18, 8, 26 ], "className" : "A_CLASS" } }, { "kind" : "TypedVar", "location" : [ 8, 29, 8, 33 ], "identifier" : { "kind" : "Identifier", "location" : [ 8, 29, 8, 29 ], "name" : "y" }, "type" : { "kind" : "ClassType", "location" : [ 8, 31, 8, 33 ], "className" : "int" } } ], "returnType" : { "kind" : "ClassType", "location" : [ 8, 39, 8, 41 ], "className" : "int" }, "declarations" : [ ], "statements" : [ { "kind" : "AssignStmt", "location" : [ 9, 9, 9, 20 ], "targets" : [ { "kind" : "Identifier", "location" : [ 9, 9, 9, 9 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "y" } ], "value" : { "kind" : "BinaryExpr", "location" : [ 9, 13, 9, 20 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "left" : { "kind" : "Identifier", "location" : [ 9, 13, 9, 13 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "y" }, "operator" : "+", "right" : { "kind" : "MemberExpr", "location" : [ 9, 15, 9, 20 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "object" : { "kind" : "Identifier", "location" : [ 9, 15, 9, 18 ], "inferredType" : { "kind" : "ClassValueType", "className" : "A_CLASS" }, "name" : "self" }, "member" : { "kind" : "Identifier", "location" : [ 9, 20, 9, 20 ], "name" : "x" } } } }, { "kind" : "ReturnStmt", "location" : [ 10, 9, 10, 16 ], "value" : { "kind" : "Identifier", "location" : [ 10, 16, 10, 16 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "y" } } ] } ] }, { "kind" : "ClassDef", "location" : [ 12, 1, 13, 21 ], "name" : { "kind" : "Identifier", "location" : [ 12, 7, 12, 13 ], "name" : "B_CLASS" }, "superClass" : { "kind" : "Identifier", "location" : [ 12, 15, 12, 20 ], "name" : "object" }, "declarations" : [ { "kind" : "VarDef", "location" : [ 13, 5, 13, 21 ], "var" : { "kind" : "TypedVar", "location" : [ 13, 5, 13, 17 ], "identifier" : { "kind" : "Identifier", "location" : [ 13, 5, 13, 13 ], "name" : "b_class_i" }, "type" : { "kind" : "ClassType", "location" : [ 13, 15, 13, 17 ], "className" : "int" } }, "value" : { "kind" : "IntegerLiteral", "location" : [ 13, 21, 13, 21 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 } } ] }, { "kind" : "ClassDef", "location" : [ 15, 1, 0, 0 ], "name" : { "kind" : "Identifier", "location" : [ 15, 7, 15, 13 ], "name" : "C_CLASS" }, "superClass" : { "kind" : "Identifier", "location" : [ 15, 15, 15, 21 ], "name" : "B_CLASS" }, "declarations" : [ ] }, { "kind" : "VarDef", "location" : [ 19, 1, 19, 15 ], "var" : { "kind" : "TypedVar", "location" : [ 19, 1, 19, 7 ], "identifier" : { "kind" : "Identifier", "location" : [ 19, 1, 19, 3 ], "name" : "a_s" }, "type" : { "kind" : "ClassType", "location" : [ 19, 5, 19, 7 ], "className" : "str" } }, "value" : { "kind" : "StringLiteral", "location" : [ 19, 11, 19, 15 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "value" : "a_s" } }, { "kind" : "VarDef", "location" : [ 20, 1, 20, 15 ], "var" : { "kind" : "TypedVar", "location" : [ 20, 1, 20, 7 ], "identifier" : { "kind" : "Identifier", "location" : [ 20, 1, 20, 3 ], "name" : "b_s" }, "type" : { "kind" : "ClassType", "location" : [ 20, 5, 20, 7 ], "className" : "str" } }, "value" : { "kind" : "StringLiteral", "location" : [ 20, 11, 20, 15 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "value" : "b_s" } }, { "kind" : "VarDef", "location" : [ 21, 1, 21, 15 ], "var" : { "kind" : "TypedVar", "location" : [ 21, 1, 21, 7 ], "identifier" : { "kind" : "Identifier", "location" : [ 21, 1, 21, 3 ], "name" : "c_s" }, "type" : { "kind" : "ClassType", "location" : [ 21, 5, 21, 7 ], "className" : "str" } }, "value" : { "kind" : "StringLiteral", "location" : [ 21, 11, 21, 15 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "value" : "c_s" } }, { "kind" : "VarDef", "location" : [ 23, 1, 23, 11 ], "var" : { "kind" : "TypedVar", "location" : [ 23, 1, 23, 7 ], "identifier" : { "kind" : "Identifier", "location" : [ 23, 1, 23, 3 ], "name" : "a_i" }, "type" : { "kind" : "ClassType", "location" : [ 23, 5, 23, 7 ], "className" : "int" } }, "value" : { "kind" : "IntegerLiteral", "location" : [ 23, 11, 23, 11 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 } }, { "kind" : "VarDef", "location" : [ 24, 1, 24, 11 ], "var" : { "kind" : "TypedVar", "location" : [ 24, 1, 24, 7 ], "identifier" : { "kind" : "Identifier", "location" : [ 24, 1, 24, 3 ], "name" : "b_i" }, "type" : { "kind" : "ClassType", "location" : [ 24, 5, 24, 7 ], "className" : "int" } }, "value" : { "kind" : "IntegerLiteral", "location" : [ 24, 11, 24, 11 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 } }, { "kind" : "VarDef", "location" : [ 25, 1, 25, 11 ], "var" : { "kind" : "TypedVar", "location" : [ 25, 1, 25, 7 ], "identifier" : { "kind" : "Identifier", "location" : [ 25, 1, 25, 3 ], "name" : "c_i" }, "type" : { "kind" : "ClassType", "location" : [ 25, 5, 25, 7 ], "className" : "int" } }, "value" : { "kind" : "IntegerLiteral", "location" : [ 25, 11, 25, 11 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 } }, { "kind" : "VarDef", "location" : [ 27, 1, 27, 16 ], "var" : { "kind" : "TypedVar", "location" : [ 27, 1, 27, 8 ], "identifier" : { "kind" : "Identifier", "location" : [ 27, 1, 27, 3 ], "name" : "a_b" }, "type" : { "kind" : "ClassType", "location" : [ 27, 5, 27, 8 ], "className" : "bool" } }, "value" : { "kind" : "BooleanLiteral", "location" : [ 27, 12, 27, 16 ], "inferredType" : { "kind" : "ClassValueType", "className" : "bool" }, "value" : false } }, { "kind" : "VarDef", "location" : [ 28, 1, 28, 16 ], "var" : { "kind" : "TypedVar", "location" : [ 28, 1, 28, 8 ], "identifier" : { "kind" : "Identifier", "location" : [ 28, 1, 28, 3 ], "name" : "b_b" }, "type" : { "kind" : "ClassType", "location" : [ 28, 5, 28, 8 ], "className" : "bool" } }, "value" : { "kind" : "BooleanLiteral", "location" : [ 28, 12, 28, 16 ], "inferredType" : { "kind" : "ClassValueType", "className" : "bool" }, "value" : false } }, { "kind" : "VarDef", "location" : [ 29, 1, 29, 16 ], "var" : { "kind" : "TypedVar", "location" : [ 29, 1, 29, 8 ], "identifier" : { "kind" : "Identifier", "location" : [ 29, 1, 29, 3 ], "name" : "c_b" }, "type" : { "kind" : "ClassType", "location" : [ 29, 5, 29, 8 ], "className" : "bool" } }, "value" : { "kind" : "BooleanLiteral", "location" : [ 29, 12, 29, 16 ], "inferredType" : { "kind" : "ClassValueType", "className" : "bool" }, "value" : false } }, { "kind" : "VarDef", "location" : [ 31, 1, 31, 19 ], "var" : { "kind" : "TypedVar", "location" : [ 31, 1, 31, 12 ], "identifier" : { "kind" : "Identifier", "location" : [ 31, 1, 31, 6 ], "name" : "a_list" }, "type" : { "kind" : "ListType", "location" : [ 31, 8, 31, 12 ], "elementType" : { "kind" : "ClassType", "location" : [ 31, 9, 31, 11 ], "className" : "int" } } }, "value" : { "kind" : "NoneLiteral", "location" : [ 31, 16, 31, 19 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" } } }, { "kind" : "VarDef", "location" : [ 32, 1, 32, 19 ], "var" : { "kind" : "TypedVar", "location" : [ 32, 1, 32, 12 ], "identifier" : { "kind" : "Identifier", "location" : [ 32, 1, 32, 6 ], "name" : "b_list" }, "type" : { "kind" : "ListType", "location" : [ 32, 8, 32, 12 ], "elementType" : { "kind" : "ClassType", "location" : [ 32, 9, 32, 11 ], "className" : "int" } } }, "value" : { "kind" : "NoneLiteral", "location" : [ 32, 16, 32, 19 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" } } }, { "kind" : "VarDef", "location" : [ 33, 1, 33, 19 ], "var" : { "kind" : "TypedVar", "location" : [ 33, 1, 33, 12 ], "identifier" : { "kind" : "Identifier", "location" : [ 33, 1, 33, 6 ], "name" : "c_list" }, "type" : { "kind" : "ListType", "location" : [ 33, 8, 33, 12 ], "elementType" : { "kind" : "ClassType", "location" : [ 33, 9, 33, 11 ], "className" : "int" } } }, "value" : { "kind" : "NoneLiteral", "location" : [ 33, 16, 33, 19 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" } } }, { "kind" : "VarDef", "location" : [ 35, 1, 35, 22 ], "var" : { "kind" : "TypedVar", "location" : [ 35, 1, 35, 15 ], "identifier" : { "kind" : "Identifier", "location" : [ 35, 1, 35, 7 ], "name" : "a_class" }, "type" : { "kind" : "ClassType", "location" : [ 35, 9, 35, 15 ], "className" : "A_CLASS" } }, "value" : { "kind" : "NoneLiteral", "location" : [ 35, 19, 35, 22 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" } } }, { "kind" : "VarDef", "location" : [ 36, 1, 36, 22 ], "var" : { "kind" : "TypedVar", "location" : [ 36, 1, 36, 15 ], "identifier" : { "kind" : "Identifier", "location" : [ 36, 1, 36, 7 ], "name" : "b_class" }, "type" : { "kind" : "ClassType", "location" : [ 36, 9, 36, 15 ], "className" : "B_CLASS" } }, "value" : { "kind" : "NoneLiteral", "location" : [ 36, 19, 36, 22 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" } } }, { "kind" : "VarDef", "location" : [ 37, 1, 37, 22 ], "var" : { "kind" : "TypedVar", "location" : [ 37, 1, 37, 15 ], "identifier" : { "kind" : "Identifier", "location" : [ 37, 1, 37, 7 ], "name" : "c_class" }, "type" : { "kind" : "ClassType", "location" : [ 37, 9, 37, 15 ], "className" : "C_CLASS" } }, "value" : { "kind" : "NoneLiteral", "location" : [ 37, 19, 37, 22 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" } } }, { "kind" : "FuncDef", "location" : [ 41, 1, 0, 0 ], "name" : { "kind" : "Identifier", "location" : [ 41, 5, 41, 7 ], "name" : "f_1" }, "params" : [ ], "returnType" : { "kind" : "ClassType", "location" : [ 41, 14, 41, 19 ], "className" : "object" }, "declarations" : [ { "kind" : "FuncDef", "location" : [ 42, 5, 44, 18 ], "name" : { "kind" : "Identifier", "location" : [ 42, 9, 42, 13 ], "name" : "f_f_1" }, "params" : [ ], "returnType" : { "kind" : "ClassType", "location" : [ 42, 20, 42, 25 ], "className" : "object" }, "declarations" : [ { "kind" : "GlobalDecl", "location" : [ 43, 9, 43, 18 ], "variable" : { "kind" : "Identifier", "location" : [ 43, 16, 43, 18 ], "name" : "a_s" } } ], "statements" : [ { "kind" : "ExprStmt", "location" : [ 44, 9, 44, 18 ], "expr" : { "kind" : "CallExpr", "location" : [ 44, 9, 44, 18 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" }, "function" : { "kind" : "Identifier", "location" : [ 44, 9, 44, 13 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ { "kind" : "ClassValueType", "className" : "object" } ], "returnType" : { "kind" : "ClassValueType", "className" : "" } }, "name" : "print" }, "args" : [ { "kind" : "Identifier", "location" : [ 44, 15, 44, 17 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "name" : "a_s" } ] } } ] } ], "statements" : [ ] }, { "kind" : "FuncDef", "location" : [ 48, 1, 0, 0 ], "name" : { "kind" : "Identifier", "location" : [ 48, 5, 48, 7 ], "name" : "f_2" }, "params" : [ ], "returnType" : { "kind" : "ClassType", "location" : [ 48, 14, 48, 19 ], "className" : "object" }, "declarations" : [ { "kind" : "VarDef", "location" : [ 49, 5, 49, 19 ], "var" : { "kind" : "TypedVar", "location" : [ 49, 5, 49, 13 ], "identifier" : { "kind" : "Identifier", "location" : [ 49, 5, 49, 9 ], "name" : "f_a_s" }, "type" : { "kind" : "ClassType", "location" : [ 49, 11, 49, 13 ], "className" : "str" } }, "value" : { "kind" : "StringLiteral", "location" : [ 49, 17, 49, 19 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "value" : "s" } }, { "kind" : "FuncDef", "location" : [ 50, 5, 52, 20 ], "name" : { "kind" : "Identifier", "location" : [ 50, 9, 50, 13 ], "name" : "f_f_2" }, "params" : [ ], "returnType" : { "kind" : "ClassType", "location" : [ 50, 20, 50, 25 ], "className" : "object" }, "declarations" : [ { "kind" : "NonLocalDecl", "location" : [ 51, 9, 51, 22 ], "variable" : { "kind" : "Identifier", "location" : [ 51, 18, 51, 22 ], "name" : "f_a_s" } } ], "statements" : [ { "kind" : "ExprStmt", "location" : [ 52, 9, 52, 20 ], "expr" : { "kind" : "CallExpr", "location" : [ 52, 9, 52, 20 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" }, "function" : { "kind" : "Identifier", "location" : [ 52, 9, 52, 13 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ { "kind" : "ClassValueType", "className" : "object" } ], "returnType" : { "kind" : "ClassValueType", "className" : "" } }, "name" : "print" }, "args" : [ { "kind" : "Identifier", "location" : [ 52, 15, 52, 19 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "name" : "f_a_s" } ] } } ] } ], "statements" : [ ] }, { "kind" : "FuncDef", "location" : [ 56, 1, 58, 18 ], "name" : { "kind" : "Identifier", "location" : [ 56, 5, 56, 7 ], "name" : "f_3" }, "params" : [ { "kind" : "TypedVar", "location" : [ 56, 9, 56, 13 ], "identifier" : { "kind" : "Identifier", "location" : [ 56, 9, 56, 9 ], "name" : "x" }, "type" : { "kind" : "ClassType", "location" : [ 56, 11, 56, 13 ], "className" : "int" } } ], "returnType" : { "kind" : "ClassType", "location" : [ 56, 19, 56, 21 ], "className" : "int" }, "declarations" : [ { "kind" : "VarDef", "location" : [ 57, 5, 57, 17 ], "var" : { "kind" : "TypedVar", "location" : [ 57, 5, 57, 13 ], "identifier" : { "kind" : "Identifier", "location" : [ 57, 5, 57, 9 ], "name" : "f_b_s" }, "type" : { "kind" : "ClassType", "location" : [ 57, 11, 57, 13 ], "className" : "int" } }, "value" : { "kind" : "IntegerLiteral", "location" : [ 57, 17, 57, 17 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 3 } } ], "statements" : [ { "kind" : "ReturnStmt", "location" : [ 58, 5, 58, 18 ], "value" : { "kind" : "BinaryExpr", "location" : [ 58, 12, 58, 18 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "left" : { "kind" : "Identifier", "location" : [ 58, 12, 58, 12 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "x" }, "operator" : "*", "right" : { "kind" : "Identifier", "location" : [ 58, 14, 58, 18 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "f_b_s" } } } ] } ], "statements" : [ { "kind" : "AssignStmt", "location" : [ 61, 1, 61, 18 ], "targets" : [ { "kind" : "Identifier", "location" : [ 61, 1, 61, 6 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "name" : "a_list" } ], "value" : { "kind" : "ListExpr", "location" : [ 61, 10, 61, 18 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "elements" : [ { "kind" : "IntegerLiteral", "location" : [ 61, 11, 61, 11 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 1 }, { "kind" : "IntegerLiteral", "location" : [ 61, 14, 61, 14 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 2 }, { "kind" : "IntegerLiteral", "location" : [ 61, 17, 61, 17 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 3 } ] } }, { "kind" : "AssignStmt", "location" : [ 62, 1, 62, 18 ], "targets" : [ { "kind" : "Identifier", "location" : [ 62, 1, 62, 6 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "name" : "b_list" } ], "value" : { "kind" : "ListExpr", "location" : [ 62, 10, 62, 18 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "elements" : [ { "kind" : "IntegerLiteral", "location" : [ 62, 11, 62, 11 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 }, { "kind" : "IntegerLiteral", "location" : [ 62, 14, 62, 14 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 }, { "kind" : "IntegerLiteral", "location" : [ 62, 17, 62, 17 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 } ] } }, { "kind" : "AssignStmt", "location" : [ 63, 1, 63, 21 ], "targets" : [ { "kind" : "Identifier", "location" : [ 63, 1, 63, 6 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "name" : "c_list" } ], "value" : { "kind" : "ListExpr", "location" : [ 63, 10, 63, 21 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "elements" : [ { "kind" : "UnaryExpr", "location" : [ 63, 11, 63, 12 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "operator" : "-", "operand" : { "kind" : "IntegerLiteral", "location" : [ 63, 12, 63, 12 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 1 } }, { "kind" : "UnaryExpr", "location" : [ 63, 15, 63, 16 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "operator" : "-", "operand" : { "kind" : "IntegerLiteral", "location" : [ 63, 16, 63, 16 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 2 } }, { "kind" : "UnaryExpr", "location" : [ 63, 19, 63, 20 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "operator" : "-", "operand" : { "kind" : "IntegerLiteral", "location" : [ 63, 20, 63, 20 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 3 } } ] } }, { "kind" : "AssignStmt", "location" : [ 65, 1, 65, 19 ], "targets" : [ { "kind" : "Identifier", "location" : [ 65, 1, 65, 7 ], "inferredType" : { "kind" : "ClassValueType", "className" : "A_CLASS" }, "name" : "a_class" } ], "value" : { "kind" : "CallExpr", "location" : [ 65, 11, 65, 19 ], "inferredType" : { "kind" : "ClassValueType", "className" : "A_CLASS" }, "function" : { "kind" : "Identifier", "location" : [ 65, 11, 65, 17 ], "name" : "A_CLASS" }, "args" : [ ] } }, { "kind" : "AssignStmt", "location" : [ 66, 1, 66, 19 ], "targets" : [ { "kind" : "Identifier", "location" : [ 66, 1, 66, 7 ], "inferredType" : { "kind" : "ClassValueType", "className" : "B_CLASS" }, "name" : "b_class" } ], "value" : { "kind" : "CallExpr", "location" : [ 66, 11, 66, 19 ], "inferredType" : { "kind" : "ClassValueType", "className" : "B_CLASS" }, "function" : { "kind" : "Identifier", "location" : [ 66, 11, 66, 17 ], "name" : "B_CLASS" }, "args" : [ ] } }, { "kind" : "AssignStmt", "location" : [ 67, 1, 67, 19 ], "targets" : [ { "kind" : "Identifier", "location" : [ 67, 1, 67, 7 ], "inferredType" : { "kind" : "ClassValueType", "className" : "C_CLASS" }, "name" : "c_class" } ], "value" : { "kind" : "CallExpr", "location" : [ 67, 11, 67, 19 ], "inferredType" : { "kind" : "ClassValueType", "className" : "C_CLASS" }, "function" : { "kind" : "Identifier", "location" : [ 67, 11, 67, 17 ], "name" : "C_CLASS" }, "args" : [ ] } }, { "kind" : "AssignStmt", "location" : [ 75, 1, 75, 15 ], "targets" : [ { "kind" : "Identifier", "location" : [ 75, 1, 75, 3 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "name" : "a_s" } ], "value" : { "kind" : "BinaryExpr", "location" : [ 75, 7, 75, 15 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "left" : { "kind" : "Identifier", "location" : [ 75, 7, 75, 9 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "name" : "a_s" }, "operator" : "+", "right" : { "kind" : "Identifier", "location" : [ 75, 13, 75, 15 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "name" : "b_s" } } }, { "kind" : "ExprStmt", "location" : [ 76, 1, 76, 10 ], "expr" : { "kind" : "CallExpr", "location" : [ 76, 1, 76, 10 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" }, "function" : { "kind" : "Identifier", "location" : [ 76, 1, 76, 5 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ { "kind" : "ClassValueType", "className" : "object" } ], "returnType" : { "kind" : "ClassValueType", "className" : "" } }, "name" : "print" }, "args" : [ { "kind" : "Identifier", "location" : [ 76, 7, 76, 9 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "name" : "a_s" } ] } }, { "kind" : "AssignStmt", "location" : [ 79, 1, 79, 12 ], "targets" : [ { "kind" : "Identifier", "location" : [ 79, 1, 79, 3 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "name" : "c_s" } ], "value" : { "kind" : "IndexExpr", "location" : [ 79, 7, 79, 12 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "list" : { "kind" : "Identifier", "location" : [ 79, 7, 79, 9 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "name" : "a_s" }, "index" : { "kind" : "IntegerLiteral", "location" : [ 79, 11, 79, 11 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 } } }, { "kind" : "ExprStmt", "location" : [ 80, 1, 80, 10 ], "expr" : { "kind" : "CallExpr", "location" : [ 80, 1, 80, 10 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" }, "function" : { "kind" : "Identifier", "location" : [ 80, 1, 80, 5 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ { "kind" : "ClassValueType", "className" : "object" } ], "returnType" : { "kind" : "ClassValueType", "className" : "" } }, "name" : "print" }, "args" : [ { "kind" : "Identifier", "location" : [ 80, 7, 80, 9 ], "inferredType" : { "kind" : "ClassValueType", "className" : "str" }, "name" : "c_s" } ] } }, { "kind" : "AssignStmt", "location" : [ 85, 1, 85, 28 ], "targets" : [ { "kind" : "Identifier", "location" : [ 85, 1, 85, 3 ], "inferredType" : { "kind" : "ClassValueType", "className" : "bool" }, "name" : "a_b" } ], "value" : { "kind" : "BinaryExpr", "location" : [ 85, 7, 85, 28 ], "inferredType" : { "kind" : "ClassValueType", "className" : "bool" }, "left" : { "kind" : "BinaryExpr", "location" : [ 85, 7, 85, 16 ], "inferredType" : { "kind" : "ClassValueType", "className" : "bool" }, "left" : { "kind" : "Identifier", "location" : [ 85, 7, 85, 9 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "a_i" }, "operator" : "==", "right" : { "kind" : "Identifier", "location" : [ 85, 14, 85, 16 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "b_i" } }, "operator" : "and", "right" : { "kind" : "UnaryExpr", "location" : [ 85, 22, 85, 28 ], "inferredType" : { "kind" : "ClassValueType", "className" : "bool" }, "operator" : "not", "operand" : { "kind" : "Identifier", "location" : [ 85, 26, 85, 28 ], "inferredType" : { "kind" : "ClassValueType", "className" : "bool" }, "name" : "b_b" } } } }, { "kind" : "ExprStmt", "location" : [ 86, 1, 86, 10 ], "expr" : { "kind" : "CallExpr", "location" : [ 86, 1, 86, 10 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" }, "function" : { "kind" : "Identifier", "location" : [ 86, 1, 86, 5 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ { "kind" : "ClassValueType", "className" : "object" } ], "returnType" : { "kind" : "ClassValueType", "className" : "" } }, "name" : "print" }, "args" : [ { "kind" : "Identifier", "location" : [ 86, 7, 86, 9 ], "inferredType" : { "kind" : "ClassValueType", "className" : "bool" }, "name" : "a_b" } ] } }, { "kind" : "AssignStmt", "location" : [ 91, 1, 91, 24 ], "targets" : [ { "kind" : "Identifier", "location" : [ 91, 1, 91, 6 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "name" : "a_list" } ], "value" : { "kind" : "BinaryExpr", "location" : [ 91, 10, 91, 24 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "left" : { "kind" : "Identifier", "location" : [ 91, 10, 91, 15 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "name" : "a_list" }, "operator" : "+", "right" : { "kind" : "Identifier", "location" : [ 91, 19, 91, 24 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "name" : "b_list" } } }, { "kind" : "AssignStmt", "location" : [ 92, 1, 92, 15 ], "targets" : [ { "kind" : "Identifier", "location" : [ 92, 1, 92, 3 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "c_i" } ], "value" : { "kind" : "IndexExpr", "location" : [ 92, 7, 92, 15 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "list" : { "kind" : "Identifier", "location" : [ 92, 7, 92, 12 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "name" : "a_list" }, "index" : { "kind" : "IntegerLiteral", "location" : [ 92, 14, 92, 14 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 0 } } }, { "kind" : "AssignStmt", "location" : [ 93, 1, 93, 13 ], "targets" : [ { "kind" : "IndexExpr", "location" : [ 93, 1, 93, 9 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "list" : { "kind" : "Identifier", "location" : [ 93, 1, 93, 6 ], "inferredType" : { "kind" : "ListValueType", "elementType" : { "kind" : "ClassValueType", "className" : "int" } }, "name" : "a_list" }, "index" : { "kind" : "IntegerLiteral", "location" : [ 93, 8, 93, 8 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 1 } } ], "value" : { "kind" : "IntegerLiteral", "location" : [ 93, 13, 93, 13 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 2 } }, { "kind" : "AssignStmt", "location" : [ 98, 1, 98, 16 ], "targets" : [ { "kind" : "Identifier", "location" : [ 98, 1, 98, 3 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "a_i" } ], "value" : { "kind" : "BinaryExpr", "location" : [ 98, 7, 98, 16 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "left" : { "kind" : "CallExpr", "location" : [ 98, 7, 98, 12 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "function" : { "kind" : "Identifier", "location" : [ 98, 7, 98, 9 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ { "kind" : "ClassValueType", "className" : "int" } ], "returnType" : { "kind" : "ClassValueType", "className" : "int" } }, "name" : "f_3" }, "args" : [ { "kind" : "IntegerLiteral", "location" : [ 98, 11, 98, 11 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 3 } ] }, "operator" : "+", "right" : { "kind" : "IntegerLiteral", "location" : [ 98, 16, 98, 16 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 5 } } }, { "kind" : "ExprStmt", "location" : [ 99, 1, 99, 5 ], "expr" : { "kind" : "CallExpr", "location" : [ 99, 1, 99, 5 ], "inferredType" : { "kind" : "ClassValueType", "className" : "object" }, "function" : { "kind" : "Identifier", "location" : [ 99, 1, 99, 3 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ ], "returnType" : { "kind" : "ClassValueType", "className" : "object" } }, "name" : "f_1" }, "args" : [ ] } }, { "kind" : "ExprStmt", "location" : [ 100, 1, 100, 5 ], "expr" : { "kind" : "CallExpr", "location" : [ 100, 1, 100, 5 ], "inferredType" : { "kind" : "ClassValueType", "className" : "object" }, "function" : { "kind" : "Identifier", "location" : [ 100, 1, 100, 3 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ ], "returnType" : { "kind" : "ClassValueType", "className" : "object" } }, "name" : "f_2" }, "args" : [ ] } }, { "kind" : "AssignStmt", "location" : [ 105, 1, 105, 20 ], "targets" : [ { "kind" : "Identifier", "location" : [ 105, 1, 105, 3 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "a_i" } ], "value" : { "kind" : "MethodCallExpr", "location" : [ 105, 7, 105, 20 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "method" : { "kind" : "MemberExpr", "location" : [ 105, 7, 105, 17 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ { "kind" : "ClassValueType", "className" : "A_CLASS" }, { "kind" : "ClassValueType", "className" : "int" } ], "returnType" : { "kind" : "ClassValueType", "className" : "int" } }, "object" : { "kind" : "Identifier", "location" : [ 105, 7, 105, 13 ], "inferredType" : { "kind" : "ClassValueType", "className" : "A_CLASS" }, "name" : "a_class" }, "member" : { "kind" : "Identifier", "location" : [ 105, 15, 105, 17 ], "name" : "add" } }, "args" : [ { "kind" : "IntegerLiteral", "location" : [ 105, 19, 105, 19 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "value" : 2 } ] } }, { "kind" : "ExprStmt", "location" : [ 106, 1, 106, 10 ], "expr" : { "kind" : "CallExpr", "location" : [ 106, 1, 106, 10 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" }, "function" : { "kind" : "Identifier", "location" : [ 106, 1, 106, 5 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ { "kind" : "ClassValueType", "className" : "object" } ], "returnType" : { "kind" : "ClassValueType", "className" : "" } }, "name" : "print" }, "args" : [ { "kind" : "Identifier", "location" : [ 106, 7, 106, 9 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "a_i" } ] } }, { "kind" : "AssignStmt", "location" : [ 109, 1, 109, 36 ], "targets" : [ { "kind" : "Identifier", "location" : [ 109, 1, 109, 3 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "a_i" } ], "value" : { "kind" : "MethodCallExpr", "location" : [ 109, 7, 109, 36 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "method" : { "kind" : "MemberExpr", "location" : [ 109, 7, 109, 17 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ { "kind" : "ClassValueType", "className" : "A_CLASS" }, { "kind" : "ClassValueType", "className" : "int" } ], "returnType" : { "kind" : "ClassValueType", "className" : "int" } }, "object" : { "kind" : "Identifier", "location" : [ 109, 7, 109, 13 ], "inferredType" : { "kind" : "ClassValueType", "className" : "A_CLASS" }, "name" : "a_class" }, "member" : { "kind" : "Identifier", "location" : [ 109, 15, 109, 17 ], "name" : "add" } }, "args" : [ { "kind" : "MemberExpr", "location" : [ 109, 19, 109, 35 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "object" : { "kind" : "Identifier", "location" : [ 109, 19, 109, 25 ], "inferredType" : { "kind" : "ClassValueType", "className" : "C_CLASS" }, "name" : "c_class" }, "member" : { "kind" : "Identifier", "location" : [ 109, 27, 109, 35 ], "name" : "b_class_i" } } ] } }, { "kind" : "ExprStmt", "location" : [ 110, 1, 110, 10 ], "expr" : { "kind" : "CallExpr", "location" : [ 110, 1, 110, 10 ], "inferredType" : { "kind" : "ClassValueType", "className" : "" }, "function" : { "kind" : "Identifier", "location" : [ 110, 1, 110, 5 ], "inferredType" : { "kind" : "FuncType", "parameters" : [ { "kind" : "ClassValueType", "className" : "object" } ], "returnType" : { "kind" : "ClassValueType", "className" : "" } }, "name" : "print" }, "args" : [ { "kind" : "Identifier", "location" : [ 110, 7, 110, 9 ], "inferredType" : { "kind" : "ClassValueType", "className" : "int" }, "name" : "a_i" } ] } } ], "errors" : { "errors" : [ ], "kind" : "Errors", "location" : [ 0, 0, 0, 0 ] } }