44 |
#define SUNDEF -1 /* For undefined user number. */ |
#define SUNDEF -1 /* For undefined user number. */ |
45 |
#define SALIAS -9991 /* for symbol generated with an alias */ |
#define SALIAS -9991 /* for symbol generated with an alias */ |
46 |
|
|
47 |
typedef struct bucket |
struct symbol_s |
48 |
{ |
{ |
49 |
/* The key, name of the symbol. */ |
/* The key, name of the symbol. */ |
50 |
char *tag; |
char *tag; |
58 |
/* Points to the other in the identifier-symbol pair for an |
/* Points to the other in the identifier-symbol pair for an |
59 |
alias. Special value SALIAS in the identifier half of the |
alias. Special value SALIAS in the identifier half of the |
60 |
identifier-symbol pair for an alias. */ |
identifier-symbol pair for an alias. */ |
61 |
struct bucket *alias; |
struct symbol_s *alias; |
62 |
symbol_class class; |
symbol_class class; |
63 |
} bucket; |
}; |
64 |
|
|
65 |
|
typedef struct symbol_s symbol_t; |
66 |
|
|
67 |
/* A function to apply to each symbol. */ |
/* A function to apply to each symbol. */ |
68 |
typedef bool (*bucket_processor) PARAMS ((bucket *)); |
typedef bool (*symbol_processor) PARAMS ((symbol_t *)); |
69 |
|
|
70 |
bucket *getsym PARAMS ((const char *)); |
symbol_t *getsym PARAMS ((const char *)); |
71 |
|
|
72 |
void buckets_new PARAMS ((void)); |
void symbols_new PARAMS ((void)); |
73 |
void buckets_do PARAMS ((bucket_processor processor, void *processor_data)); |
void symbols_do PARAMS ((symbol_processor processor, void *processor_data)); |
74 |
void buckets_free PARAMS ((void)); |
void symbols_free PARAMS ((void)); |
75 |
|
|
76 |
#endif /* !SYMTAB_H_ */ |
#endif /* !SYMTAB_H_ */ |