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

@@ -420,7 +420,10 @@ emit_node :: (state : *Codegen_State, node : *AST_Node, indentation : int) {
}
}
case .Unary; {
assert(false, "Not implemented yet: unary");
indent(*state.builder, indentation);
emit_operator(state, node.token.kind);
emit_node(state, node.children[0], 0);
}
case .Expression_Statement; {
emit_node(state, node.children[0], indentation);