#ifndef ID_H #define ID_H #include #include "jrb.h" struct id; struct tree { int (*comp)(const void *a, const void *b); struct jrb *root; }; struct id { struct jrb *jrb; const char *s; size_t len; }; int comp_id(const void *a, const void *b); struct tree *make_tree(int (*comp)(const void *a, const void *b)); struct id *make_id(struct tree *tree, const char *s, size_t len); const struct id *find_id(const struct tree *tree, const char *s, size_t len); const struct id *first_id(const struct tree *tree); const struct id *next_id(const struct id *id); #endif /* !ID_H */