tcp: Fix 64 bit build with debugging features enabled.
[haiku.git] / src / kits / network / netresolv / include / isc / tree.h
blob96feaca68d54d9a0db72a5b07a249f57fd4e5dd8
1 /* tree.h - declare structures used by tree library
3 * vix 22jan93 [revisited; uses RCS, ANSI, POSIX; has bug fixes]
4 * vix 27jun86 [broken out of tree.c]
6 * $Id: tree.h,v 1.3 2005/04/27 04:56:18 sra Exp $
7 */
10 #ifndef _TREE_H_INCLUDED
11 #define _TREE_H_INCLUDED
14 #ifndef __P
15 # if defined(__STDC__) || defined(__GNUC__)
16 # define __P(x) x
17 # else
18 # define __P(x) ()
19 # endif
20 #endif
22 /*%
23 * tree_t is our package-specific anonymous pointer.
25 #if defined(__STDC__) || defined(__GNUC__)
26 typedef void *tree_t;
27 #else
28 typedef char *tree_t;
29 #endif
31 /*%
32 * Do not taint namespace
34 #define tree_add __tree_add
35 #define tree_delete __tree_delete
36 #define tree_init __tree_init
37 #define tree_mung __tree_mung
38 #define tree_srch __tree_srch
39 #define tree_trav __tree_trav
42 typedef struct tree_s {
43 tree_t data;
44 struct tree_s *left, *right;
45 short bal;
47 tree;
50 void tree_init __P((tree **));
51 tree_t tree_srch __P((tree **, int (*)(), tree_t));
52 tree_t tree_add __P((tree **, int (*)(), tree_t, void (*)()));
53 int tree_delete __P((tree **, int (*)(), tree_t, void (*)()));
54 int tree_trav __P((tree **, int (*)()));
55 void tree_mung __P((tree **, void (*)()));
58 #endif /* _TREE_H_INCLUDED */
59 /*! \file */