Added broken check for bool if cond. Also added some wonky if/else pretty printing for AST.

This commit is contained in:
2025-01-13 16:33:03 +01:00
parent 4b927b6be9
commit aaeda22fa3
9 changed files with 165 additions and 14 deletions

View File

@@ -763,6 +763,7 @@ statement :: (parse_state : *Parse_State) -> *AST_Node {
source_location.begin = parse_state.previous;
if_expression := expression(parse_state);
add_child(node, if_expression);
// consume(parse_state, .TOKEN_LEFTBRACE, "Expect '{' after if-condition.");
if_body := block(parse_state);