tsearch.h 585 B

12345678910111213141516171819202122232425262728
  1. #ifndef TSEARCH_H
  2. #define TSEARCH_H
  3. typedef struct hc_node_t
  4. {
  5. const void *key;
  6. struct hc_node_t *left;
  7. struct hc_node_t *right;
  8. unsigned int red:1;
  9. } *hc_node;
  10. typedef const struct hc_node_t *hc_const_node;
  11. typedef void (*__hc_free_fn_t) (void *__hc_nodep);
  12. typedef int (*__hc_compar_fn_t) (__const void *, __const void *);
  13. void *
  14. __hc_tsearch (const void *key, void **vrootp, __hc_compar_fn_t compar);
  15. void *
  16. __hc_tfind (const void *key, void *const *vrootp, __hc_compar_fn_t compar);
  17. void
  18. __hc_tdestroy (void *vroot, __hc_free_fn_t freefct);
  19. #endif /* TSEARCH_H */