summaryrefslogtreecommitdiff
path: root/string/string.h
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2016-08-20 19:50:45 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2016-08-20 19:50:45 +0200
commit4dd9e35bfd35d3138bc44169baba098005bad51e (patch)
treea4939c43a9c3fe00eb27f023e14acc5e1fe8808c /string/string.h
parentbd42a4599d1b6f77bcfe1e4f67b7cbd9e1cb2dfd (diff)
parentf76453c31593957fec1a99b986bfa5506618b79c (diff)
Merge commit 'refs/top-bases/t/bigmem' into t/bigmem
Diffstat (limited to 'string/string.h')
-rw-r--r--string/string.h27
1 files changed, 11 insertions, 16 deletions
diff --git a/string/string.h b/string/string.h
index b127e8d9dd..54a4d39a53 100644
--- a/string/string.h
+++ b/string/string.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991-2014 Free Software Foundation, Inc.
+/* Copyright (C) 1991-2015 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
@@ -31,12 +31,8 @@ __BEGIN_DECLS
#define __need_NULL
#include <stddef.h>
-/* Provide correct C++ prototypes, and indicate this to the caller. This
- requires a compatible C++ standard library. As a heuristic, we provide
- these when the compiler indicates full conformance with C++98 or later,
- and for older GCC versions that are known to provide a compatible
- libstdc++. */
-#if defined __cplusplus && (__cplusplus >= 199711L || __GNUC_PREREQ (4, 4))
+/* Tell the caller that we provide correct C++ prototypes. */
+#if defined __cplusplus && __GNUC_PREREQ (4, 4)
# define __CORRECT_ISO_CPP_STRING_H_PROTO
#endif
@@ -54,11 +50,11 @@ __END_NAMESPACE_STD
/* Copy no more than N bytes of SRC to DEST, stopping when C is found.
Return the position in DEST one byte past where C was copied,
or NULL if C was not found in the first N bytes of SRC. */
-#if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN
+#if defined __USE_MISC || defined __USE_XOPEN
extern void *memccpy (void *__restrict __dest, const void *__restrict __src,
int __c, size_t __n)
__THROW __nonnull ((1, 2));
-#endif /* SVID. */
+#endif /* Misc || X/Open. */
__BEGIN_NAMESPACE_STD
@@ -170,8 +166,7 @@ extern size_t strxfrm_l (char *__dest, const char *__src, size_t __n,
__locale_t __l) __THROW __nonnull ((2, 4));
#endif
-#if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN_EXTENDED \
- || defined __USE_XOPEN2K8
+#if defined __USE_XOPEN_EXTENDED || defined __USE_XOPEN2K8
/* Duplicate S, returning an identical malloc'd string. */
extern char *strdup (const char *__s)
__THROW __attribute_malloc__ __nonnull ((1));
@@ -355,7 +350,7 @@ extern char *__strtok_r (char *__restrict __s,
const char *__restrict __delim,
char **__restrict __save_ptr)
__THROW __nonnull ((2, 3));
-#if defined __USE_POSIX || defined __USE_MISC
+#ifdef __USE_POSIX
extern char *strtok_r (char *__restrict __s, const char *__restrict __delim,
char **__restrict __save_ptr)
__THROW __nonnull ((2, 3));
@@ -412,7 +407,7 @@ __BEGIN_NAMESPACE_STD
/* Return a string describing the meaning of the `errno' code in ERRNUM. */
extern char *strerror (int __errnum) __THROW;
__END_NAMESPACE_STD
-#if defined __USE_XOPEN2K || defined __USE_MISC
+#ifdef __USE_XOPEN2K
/* Reentrant version of `strerror'.
There are 2 flavors of `strerror_r', GNU which returns the string
and may or may not use the supplied temporary buffer and POSIX one
@@ -450,7 +445,7 @@ extern char *strerror_l (int __errnum, __locale_t __l) __THROW;
the namespace rules does not allow this. */
extern void __bzero (void *__s, size_t __n) __THROW __nonnull ((1));
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Copy N bytes of SRC to DEST (like memmove, but args reversed). */
extern void bcopy (const void *__src, void *__dest, size_t __n)
__THROW __nonnull ((1, 2));
@@ -537,7 +532,7 @@ extern int strcasecmp (const char *__s1, const char *__s2)
/* Compare no more than N chars of S1 and S2, ignoring case. */
extern int strncasecmp (const char *__s1, const char *__s2, size_t __n)
__THROW __attribute_pure__ __nonnull ((1, 2));
-#endif /* Use BSD. */
+#endif /* Use misc. */
#ifdef __USE_GNU
/* Again versions of a few functions which use the given locale instead
@@ -551,7 +546,7 @@ extern int strncasecmp_l (const char *__s1, const char *__s2,
__THROW __attribute_pure__ __nonnull ((1, 2, 4));
#endif
-#ifdef __USE_BSD
+#ifdef __USE_MISC
/* Return the next DELIM-delimited token from *STRINGP,
terminating it with a '\0', and update *STRINGP to point past it. */
extern char *strsep (char **__restrict __stringp,