Adding parent nodes to asts

This commit is contained in:
Krzosa Karol
2022-05-27 16:19:18 +02:00
parent 8fb29e21d1
commit 798453c7db
6 changed files with 47 additions and 57 deletions

View File

@@ -39,8 +39,6 @@ struct Operand{
global Ast_Named empty_decl = {};
// @todo: currently inserting into sym table type of [Type] instead of what type represents
function void
sym_insert(Sym *sym){
U64 hash = hash_string(sym->name.s);
@@ -229,7 +227,10 @@ eval_stmt(Ast *ast, Ast_Resolved_Type *ret){
}
}
enum{AST_CAN_BE_NULL = 1};
enum{
AST_CAN_BE_NULL = 1
};
function Ast_Resolved_Type *
eval_typespec(Ast_Expr *ast, B32 ast_can_be_null){
if(ast_can_be_null && ast == 0) return 0;