if else if else if if else if else

This commit is contained in:
2025-01-20 22:20:47 +01:00
parent 45ea54cf93
commit 42c5baa846
14 changed files with 220 additions and 12 deletions

View File

@@ -1502,6 +1502,12 @@ check_node :: (checker : *Semantic_Checker, node : *AST_Node) -> Type_Variable_H
if_condition_has_to_be_boolean_type(checker, node, cond_var);
}
}
body_var := check_block(checker, node.children[1]);
if node.children.count == 3 {
else_var := check_node(checker, node.children[2]);
}
}
case .Variable; {
return create_variable(checker, node);