ref: 5956b8e016a018b2701f8651e328f7ddae62084f
parent: 9b4d794ae6c685b822c9318d2f343ca5e5814ffc
author: Roberto E. Vargas Caballero <[email protected]>
date: Thu Jul 10 15:54:06 EDT 2014
Add typedef handling This is a first version of types defined by the user. I am pretty sure this version is not going to work, but it is good enough to can create a commit.
--- a/cc1/decl.c
+++ b/cc1/decl.c
@@ -410,8 +410,9 @@
switch (sclass) {
case TYPEDEF:
- /* TODO: */
- break;
+ sym->token = TYPE;
+ sym->u.token = TYPENAME;
+ continue;
case STATIC:
sym->s.isstatic = 1;
break;
@@ -486,7 +487,10 @@
case EXTERN:
sym->s.isdefined = 0;
break;
- case TYPEDEF: /* TODO: */ break;
+ case TYPEDEF:
+ sym->token = TYPE;
+ sym->u.token = TYPENAME;
+ continue;
}
if (BTYPE(tp) != FTN) {