hi i had a go at implementing a symbol table,
is this valid?
char Table[MAX][MIN]= {"unsigned", "int", "unsigned", "char",
"void","void";};
and also..does anyone know what the identifiers are for the reserved words in c?
thanks
hi i had a go at implementing a symbol table,
is this valid?
char Table[MAX][MIN]= {"unsigned", "int", "unsigned", "char",
"void","void";};
and also..does anyone know what the identifiers are for the reserved words in c?
thanks
a symbol table should look like the above. assuming you are the same poster as last time asking about how the compiler works, you'll probably want to use another structure such as a hash table to store all the identifiers you collect.Code:enum types { UNSIGNED }; typedef struct t_sym symtbl; struct t_sym { char *ident; uint type; }; symtbl ctok { "unsigned", UNSIGNED NULL, -1 };
.sect signature
>and also..does anyone know what the identifiers are for the reserved words in c?
Here is a list of keywords. Here is a list of reserved identifiers.
does anyone know of any websites that show you how to create a symbol table step by step...i cant get my head round it...i've been trying for 10 hours straight my assignments due in next week if i dont get this right i fail the course i got no access to any lecturers either.....plz help all i need is some basic instuction on how to implement a symbol table and compare stuff to them....plz anyone????