Added unary expressions to semcheck and codegen.

This commit is contained in:
2025-01-08 22:37:48 +01:00
parent 1adb289c10
commit 4053400152
25 changed files with 149 additions and 24 deletions

View File

@@ -211,7 +211,11 @@ pretty_print_binary :: (node : *AST_Node, indentation : int, builder : *String_B
}
pretty_print_unary :: (node : *AST_Node, indentation : int, builder : *String_Builder) {
indent(builder, indentation);
op := node.token;
print_to_builder(builder, op_to_string(op));
pretty_print_children(node, 0, builder, flags = 0);
}
print_return_node :: (node : *AST_Node, indentation : int, builder : *String_Builder) {