diff options
author | Jim Meyering <jim@meyering.net> | 2003-02-06 10:13:28 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2003-02-06 10:13:28 +0000 |
commit | ac0250af06f90061bb425d99a4ccc3832b1eeac3 (patch) | |
tree | 1ee8195be9a167d8909dfa6aa42bec3bb5430151 | |
parent | 0e4da9fc4f75ef10258b7141bb97282b4f537c9f (diff) | |
download | coreutils-ac0250af06f90061bb425d99a4ccc3832b1eeac3.tar.xz |
(__restrict): Define to `restrict' or to nothing.
-rw-r--r-- | lib/search_.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/lib/search_.h b/lib/search_.h index 626362270..78e3980ec 100644 --- a/lib/search_.h +++ b/lib/search_.h @@ -22,6 +22,18 @@ typedef enum } VISIT; +/* GCC 2.95 and later have "__restrict"; C99 compilers have + "restrict", and "configure" may have defined "restrict". */ +#ifndef __restrict +# if ! (2 < __GNUC__ || (2 == __GNUC__ && 95 <= __GNUC_MINOR__)) +# if defined restrict || 199901L <= __STDC_VERSION__ +# define __restrict restrict +# else +# define __restrict +# endif +# endif +#endif + /* 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 (const void *__key, void **__rootp, |