Misc changes

This commit is contained in:
Krzosa Karol
2022-12-31 14:16:46 +01:00
parent e07ad3c86d
commit 673db72e29
9 changed files with 174 additions and 76 deletions

View File

@@ -96,7 +96,24 @@ struct Ast_Atom: Ast_Expr{
// resolved_type is a solid type that
// can be use during code generation
// it cannot be untyped. (or at least thats the hope :)
INLINE_VALUE_FIELDS;
/*#import meta
meta.inline_value_fields()
*/
union {
Value value;
struct {
Ast_Type *type;
Ast_Decl *resolved_decl;
union {
bool bool_val;
F64 f64_val;
Intern_String intern_val;
BigInt big_int_val;
Ast_Type *type_val;
};
};
};
/*END*/
};
typedef U32 Ast_Call_Item_Flag;
@@ -287,7 +304,24 @@ struct Ast_Decl: Ast{
Ast_Lambda *lambda;
};
INLINE_VALUE_FIELDS;
/*#import meta
meta.inline_value_fields()
*/
union {
Value value;
struct {
Ast_Type *type;
Ast_Decl *resolved_decl;
union {
bool bool_val;
F64 f64_val;
Intern_String intern_val;
BigInt big_int_val;
Ast_Type *type_val;
};
};
};
/*END*/
};
//-----------------------------------------------------------------------------