ceptr
 All Data Structures Files Functions Variables Typedefs Macros Modules Pages
semtable.h
Go to the documentation of this file.
1 
9 #ifndef _CEPTR_SEMTABLE_H
10 #define _CEPTR_SEMTABLE_H
11 
12 #include "ceptr_types.h"
13 #include "ceptr_error.h"
14 
15 SemTable *_sem_new();
16 int _sem_new_context(SemTable *sem,T *definitions);
17 void _sem_free(SemTable *sem);
18 #define _sem_context(sem,s) __sem_context(sem,(s).context)
19 ContextStore *__sem_context(SemTable *sem,Context c);
20 void _sem_free_context(SemTable *sem,Context c);
21 #define _sem_get_defs(sem,s) __sem_get_defs(sem,(s).semtype,(s).context)
22 T *__sem_get_defs(SemTable *st,SemanticType semtype,Context c);
23 #define _sem_get_def(sem,s) __sem_get_def(sem,(s).semtype,(s).context,(s).id)
24 T *__sem_get_def(SemTable *sem,SemanticType semtype,Context c,SemanticAddr i);
25 char *_sem_get_name(SemTable *sem,SemanticID s);
26 T * _sem_get_label(SemTable *sem,SemanticID s,Symbol label_type);
27 void _sem_add_label(SemTable *sem,SemanticID s,Symbol label_type,char *label);
28 Structure _sem_get_symbol_structure(SemTable *sem,Symbol s);
29 bool __sem_get_by_label(SemTable *sem,char *label,SemanticID *s,Context ctx);
30 bool _sem_get_by_label(SemTable *sem,char *label,SemanticID *s);
31 
32 #endif
Definition: ceptr_types.h:114
void _sem_add_label(SemTable *sem, SemanticID s, Symbol label_type, char *label)
Definition: semtable.c:148
T * _sem_get_label(SemTable *sem, SemanticID s, Symbol label_type)
Definition: semtable.c:124
char * _sem_get_name(SemTable *sem, SemanticID s)
Definition: semtable.c:85