diff options
Diffstat (limited to 'scope.h')
-rw-r--r-- | scope.h | 21 |
1 files changed, 21 insertions, 0 deletions
@@ -0,0 +1,21 @@ +struct scope { + struct hashtable *tags; + struct hashtable *decls; + struct value *breaklabel; + struct value *continuelabel; + struct switchcases *switchcases; + struct scope *parent; +}; + +struct scope *mkscope(struct scope *); +struct scope *delscope(struct scope *); + +struct declaration; +void scopeputdecl(struct scope *, const char *, struct declaration *); +struct declaration *scopegetdecl(struct scope *, const char *, _Bool); + +struct type; +void scopeputtag(struct scope *, const char *, struct type *); +struct type *scopegettag(struct scope *, const char *, _Bool); + +extern struct scope filescope; |