]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Avoid namespace pollution.
authorUlrich Drepper <drepper@redhat.com>
Thu, 26 Aug 1999 00:26:16 +0000 (00:26 +0000)
committerUlrich Drepper <drepper@redhat.com>
Thu, 26 Aug 1999 00:26:16 +0000 (00:26 +0000)
misc/search.h

index b534d93ccb22407a0217b71bb84bece7b689e062..8fb2539cd10fbdcfc1b722c4b21838e50bb14022 100644 (file)
@@ -1,5 +1,5 @@
 /* Declarations for System V style searching functions.
-   Copyright (C) 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
+   Copyright (C) 1995, 1996, 1997, 1998, 1999 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -23,7 +23,6 @@
 #include <features.h>
 
 #define __need_size_t
-#define __need_NULL
 #include <stddef.h>
 
 __BEGIN_DECLS
@@ -32,12 +31,14 @@ __BEGIN_DECLS
 /* Prototype structure for a linked-list data structure.
    This is the type used by the `insque' and `remque' functions.  */
 
+# ifdef __USE_GNU
 struct qelem
   {
     struct qelem *q_forw;
     struct qelem *q_back;
     char q_data[1];
   };
+# endif
 
 
 /* Insert ELEM into a doubly-linked list, after PREV.  */
@@ -105,8 +106,8 @@ struct hsearch_data
    same time.  */
 extern int hsearch_r __P ((ENTRY __item, ACTION __action, ENTRY **__retval,
                           struct hsearch_data *__htab));
-extern int hcreate_r __P ((size_t __nel, struct hsearch_data *htab));
-extern void hdestroy_r __P ((struct hsearch_data *htab));
+extern int hcreate_r __P ((size_t __nel, struct hsearch_data *__htab));
+extern void hdestroy_r __P ((struct hsearch_data *__htab));
 #endif
 
 
@@ -127,16 +128,16 @@ VISIT;
 /* Search for an entry matching the given KEY in the tree pointed to
    by *ROOTP and insert a new element if not found.  */
 extern void *tsearch __PMT ((__const void *__key, void **__rootp,
-                            __compar_fn_t compar));
+                            __compar_fn_t __compar));
 
 /* Search for an entry matching the given KEY in the tree pointed to
    by *ROOTP.  If no matching entry is available return NULL.  */
 extern void *tfind __PMT ((__const void *__key, void *__const *__rootp,
-                          __compar_fn_t compar));
+                          __compar_fn_t __compar));
 
 /* Remove the element matching KEY from the tree pointed to by *ROOTP.  */
 extern void *tdelete __PMT ((__const void *__key, void **__rootp,
-                            __compar_fn_t compar));
+                            __compar_fn_t __compar));
 
 #ifndef __ACTION_FN_T
 # define __ACTION_FN_T
@@ -147,7 +148,7 @@ typedef void (*__action_fn_t) __PMT ((__const void *__nodep,
 
 /* Walk through the whole tree and call the ACTION callback for every node
    or leaf.  */
-extern void twalk __PMT ((__const void *__root, __action_fn_t action));
+extern void twalk __PMT ((__const void *__root, __action_fn_t __action));
 
 #ifdef __USE_GNU
 /* Callback type for function to free a tree node.  If the keys are atomic
@@ -155,7 +156,7 @@ extern void twalk __PMT ((__const void *__root, __action_fn_t action));
 typedef void (*__free_fn_t) __PMT ((void *__nodep));
 
 /* Destroy the whole tree, call FREEFCT for each node or leaf.  */
-extern void tdestroy __PMT ((void *__root, __free_fn_t freefct));
+extern void tdestroy __PMT ((void *__root, __free_fn_t __freefct));
 #endif