From 3b2503978998ee1e8d4aeebbdbfb743f125e1b5e Mon Sep 17 00:00:00 2001 From: Nicholas Noll Date: Fri, 29 May 2020 14:55:24 -0700 Subject: switch types to be integers into the main database --- sys/cmd/cc/cc.h | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'sys/cmd/cc/cc.h') diff --git a/sys/cmd/cc/cc.h b/sys/cmd/cc/cc.h index e711770..44b0037 100644 --- a/sys/cmd/cc/cc.h +++ b/sys/cmd/cc/cc.h @@ -245,7 +245,7 @@ struct Sym union { string macro; Decl *obj; - Type *typ; + int32 type; Stmt *blk; Expr *val; }; @@ -400,7 +400,7 @@ struct Key struct Expr { struct Node; - Type *type; + int32 type; union { struct { uint64 kind; @@ -438,7 +438,7 @@ struct Expr Expr *post; } unary; struct { - Type *to; + int32 to; Expr *x; } cast; struct { @@ -597,14 +597,14 @@ struct Dtor struct Field { uint32 qual; - Type *type; + uint32 type; string name; }; struct Decls { string name; - Type *type; + uint32 type; Expr *init; struct Decls *link; }; @@ -617,7 +617,7 @@ struct Decl union { struct { string name; - Type *type; + uint32 type; union { Stmt *body; Expr *init; @@ -649,12 +649,12 @@ struct Type union { struct { uint32 qual; - Type *base; + uint32 base; } ptr; struct { int len; uint32 qual; - Type *elt; + uint32 *elt; } arr; struct { int len; @@ -667,7 +667,7 @@ struct Type Expr *val; } enm; struct { - Type *ret; + uint32 ret; int n; int dots : 1; Field *arg; @@ -768,6 +768,6 @@ extern Compiler C; /* cc.c functions */ void init(); int32 intern(byte **str); -Type *type(); +int32 type(); #undef iota -- cgit v1.2.1