Blame gl/string.in.h

Packit Service 4684c1
/* A GNU-like <string.h>.
Packit Service 4684c1
Packit Service 4684c1
   Copyright (C) 1995-1996, 2001-2020 Free Software Foundation, Inc.
Packit Service 4684c1
Packit Service 4684c1
   This program is free software; you can redistribute it and/or modify
Packit Service 4684c1
   it under the terms of the GNU Lesser General Public License as published by
Packit Service 4684c1
   the Free Software Foundation; either version 2.1, or (at your option)
Packit Service 4684c1
   any later version.
Packit Service 4684c1
Packit Service 4684c1
   This program is distributed in the hope that it will be useful,
Packit Service 4684c1
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit Service 4684c1
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
Packit Service 4684c1
   GNU Lesser General Public License for more details.
Packit Service 4684c1
Packit Service 4684c1
   You should have received a copy of the GNU Lesser General Public License
Packit Service 4684c1
   along with this program; if not, see <https://www.gnu.org/licenses/>.  */
Packit Service 4684c1
Packit Service 4684c1
#if __GNUC__ >= 3
Packit Service 4684c1
@PRAGMA_SYSTEM_HEADER@
Packit Service 4684c1
#endif
Packit Service 4684c1
@PRAGMA_COLUMNS@
Packit Service 4684c1
Packit Service 4684c1
#if defined _GL_ALREADY_INCLUDING_STRING_H
Packit Service 4684c1
/* Special invocation convention:
Packit Service 4684c1
   - On OS X/NetBSD we have a sequence of nested includes
Packit Service 4684c1
       <string.h> -> <strings.h> -> "string.h"
Packit Service 4684c1
     In this situation system _chk variants due to -D_FORTIFY_SOURCE
Packit Service 4684c1
     might be used after any replacements defined here.  */
Packit Service 4684c1
Packit Service 4684c1
#@INCLUDE_NEXT@ @NEXT_STRING_H@
Packit Service 4684c1
Packit Service 4684c1
#else
Packit Service 4684c1
/* Normal invocation convention.  */
Packit Service 4684c1
Packit Service 4684c1
#ifndef _@GUARD_PREFIX@_STRING_H
Packit Service 4684c1
Packit Service 4684c1
#define _GL_ALREADY_INCLUDING_STRING_H
Packit Service 4684c1
Packit Service 4684c1
/* The include_next requires a split double-inclusion guard.  */
Packit Service 4684c1
#@INCLUDE_NEXT@ @NEXT_STRING_H@
Packit Service 4684c1
Packit Service 4684c1
#undef _GL_ALREADY_INCLUDING_STRING_H
Packit Service 4684c1
Packit Service 4684c1
#ifndef _@GUARD_PREFIX@_STRING_H
Packit Service 4684c1
#define _@GUARD_PREFIX@_STRING_H
Packit Service 4684c1
Packit Service 4684c1
/* NetBSD 5.0 mis-defines NULL.  */
Packit Service 4684c1
#include <stddef.h>
Packit Service 4684c1
Packit Service 4684c1
/* MirBSD defines mbslen as a macro.  */
Packit Service 4684c1
#if @GNULIB_MBSLEN@ && defined __MirBSD__
Packit Service 4684c1
# include <wchar.h>
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* The __attribute__ feature is available in gcc versions 2.5 and later.
Packit Service 4684c1
   The attribute __pure__ was added in gcc 2.96.  */
Packit Service 4684c1
#ifndef _GL_ATTRIBUTE_PURE
Packit Service 4684c1
# if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 96)
Packit Service 4684c1
#  define _GL_ATTRIBUTE_PURE __attribute__ ((__pure__))
Packit Service 4684c1
# else
Packit Service 4684c1
#  define _GL_ATTRIBUTE_PURE /* empty */
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* NetBSD 5.0 declares strsignal in <unistd.h>, not in <string.h>.  */
Packit Service 4684c1
/* But in any case avoid namespace pollution on glibc systems.  */
Packit Service 4684c1
#if (@GNULIB_STRSIGNAL@ || defined GNULIB_POSIXCHECK) && defined __NetBSD__ \
Packit Service 4684c1
    && ! defined __GLIBC__
Packit Service 4684c1
# include <unistd.h>
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* The definitions of _GL_FUNCDECL_RPL etc. are copied here.  */
Packit Service 4684c1
Packit Service 4684c1
/* The definition of _GL_ARG_NONNULL is copied here.  */
Packit Service 4684c1
Packit Service 4684c1
/* The definition of _GL_WARN_ON_USE is copied here.  */
Packit Service 4684c1
Packit Service 4684c1
Packit Service 4684c1
/* Clear a block of memory.  The compiler will not delete a call to
Packit Service 4684c1
   this function, even if the block is dead after the call.  */
Packit Service 4684c1
#if @GNULIB_EXPLICIT_BZERO@
Packit Service 4684c1
# if ! @HAVE_EXPLICIT_BZERO@
Packit Service 4684c1
_GL_FUNCDECL_SYS (explicit_bzero, void,
Packit Service 4684c1
                  (void *__dest, size_t __n) _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (explicit_bzero, void, (void *__dest, size_t __n));
Packit Service 4684c1
_GL_CXXALIASWARN (explicit_bzero);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef explicit_bzero
Packit Service 4684c1
# if HAVE_RAW_DECL_EXPLICIT_BZERO
Packit Service 4684c1
_GL_WARN_ON_USE (explicit_bzero, "explicit_bzero is unportable - "
Packit Service 4684c1
                 "use gnulib module explicit_bzero for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Find the index of the least-significant set bit.  */
Packit Service 4684c1
#if @GNULIB_FFSL@
Packit Service 4684c1
# if !@HAVE_FFSL@
Packit Service 4684c1
_GL_FUNCDECL_SYS (ffsl, int, (long int i));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (ffsl, int, (long int i));
Packit Service 4684c1
_GL_CXXALIASWARN (ffsl);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef ffsl
Packit Service 4684c1
# if HAVE_RAW_DECL_FFSL
Packit Service 4684c1
_GL_WARN_ON_USE (ffsl, "ffsl is not portable - use the ffsl module");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
Packit Service 4684c1
/* Find the index of the least-significant set bit.  */
Packit Service 4684c1
#if @GNULIB_FFSLL@
Packit Service 4684c1
# if !@HAVE_FFSLL@
Packit Service 4684c1
_GL_FUNCDECL_SYS (ffsll, int, (long long int i));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (ffsll, int, (long long int i));
Packit Service 4684c1
_GL_CXXALIASWARN (ffsll);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef ffsll
Packit Service 4684c1
# if HAVE_RAW_DECL_FFSLL
Packit Service 4684c1
_GL_WARN_ON_USE (ffsll, "ffsll is not portable - use the ffsll module");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
Packit Service 4684c1
/* Return the first instance of C within N bytes of S, or NULL.  */
Packit Service 4684c1
#if @GNULIB_MEMCHR@
Packit Service 4684c1
# if @REPLACE_MEMCHR@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   define memchr rpl_memchr
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (memchr, void *, (void const *__s, int __c, size_t __n)
Packit Service 4684c1
                                  _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                  _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (memchr, void *, (void const *__s, int __c, size_t __n));
Packit Service 4684c1
# else
Packit Service 4684c1
#  if ! @HAVE_MEMCHR@
Packit Service 4684c1
_GL_FUNCDECL_SYS (memchr, void *, (void const *__s, int __c, size_t __n)
Packit Service 4684c1
                                  _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                  _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
#  endif
Packit Service 4684c1
  /* On some systems, this function is defined as an overloaded function:
Packit Service 4684c1
       extern "C" { const void * std::memchr (const void *, int, size_t); }
Packit Service 4684c1
       extern "C++" { void * std::memchr (void *, int, size_t); }  */
Packit Service 4684c1
_GL_CXXALIAS_SYS_CAST2 (memchr,
Packit Service 4684c1
                        void *, (void const *__s, int __c, size_t __n),
Packit Service 4684c1
                        void const *, (void const *__s, int __c, size_t __n));
Packit Service 4684c1
# endif
Packit Service 4684c1
# if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
Packit Service 4684c1
     && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
Packit Service 4684c1
_GL_CXXALIASWARN1 (memchr, void *, (void *__s, int __c, size_t __n));
Packit Service 4684c1
_GL_CXXALIASWARN1 (memchr, void const *,
Packit Service 4684c1
                   (void const *__s, int __c, size_t __n));
Packit Service 4684c1
# elif __GLIBC__ >= 2
Packit Service 4684c1
_GL_CXXALIASWARN (memchr);
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef memchr
Packit Service 4684c1
/* Assume memchr is always declared.  */
Packit Service 4684c1
_GL_WARN_ON_USE (memchr, "memchr has platform-specific bugs - "
Packit Service 4684c1
                 "use gnulib module memchr for portability" );
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Return the first occurrence of NEEDLE in HAYSTACK.  */
Packit Service 4684c1
#if @GNULIB_MEMMEM@
Packit Service 4684c1
# if @REPLACE_MEMMEM@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   define memmem rpl_memmem
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (memmem, void *,
Packit Service 4684c1
                  (void const *__haystack, size_t __haystack_len,
Packit Service 4684c1
                   void const *__needle, size_t __needle_len)
Packit Service 4684c1
                  _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                  _GL_ARG_NONNULL ((1, 3)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (memmem, void *,
Packit Service 4684c1
                  (void const *__haystack, size_t __haystack_len,
Packit Service 4684c1
                   void const *__needle, size_t __needle_len));
Packit Service 4684c1
# else
Packit Service 4684c1
#  if ! @HAVE_DECL_MEMMEM@
Packit Service 4684c1
_GL_FUNCDECL_SYS (memmem, void *,
Packit Service 4684c1
                  (void const *__haystack, size_t __haystack_len,
Packit Service 4684c1
                   void const *__needle, size_t __needle_len)
Packit Service 4684c1
                  _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                  _GL_ARG_NONNULL ((1, 3)));
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (memmem, void *,
Packit Service 4684c1
                  (void const *__haystack, size_t __haystack_len,
Packit Service 4684c1
                   void const *__needle, size_t __needle_len));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIASWARN (memmem);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef memmem
Packit Service 4684c1
# if HAVE_RAW_DECL_MEMMEM
Packit Service 4684c1
_GL_WARN_ON_USE (memmem, "memmem is unportable and often quadratic - "
Packit Service 4684c1
                 "use gnulib module memmem-simple for portability, "
Packit Service 4684c1
                 "and module memmem for speed" );
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Copy N bytes of SRC to DEST, return pointer to bytes after the
Packit Service 4684c1
   last written byte.  */
Packit Service 4684c1
#if @GNULIB_MEMPCPY@
Packit Service 4684c1
# if ! @HAVE_MEMPCPY@
Packit Service 4684c1
_GL_FUNCDECL_SYS (mempcpy, void *,
Packit Service 4684c1
                  (void *restrict __dest, void const *restrict __src,
Packit Service 4684c1
                   size_t __n)
Packit Service 4684c1
                  _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (mempcpy, void *,
Packit Service 4684c1
                  (void *restrict __dest, void const *restrict __src,
Packit Service 4684c1
                   size_t __n));
Packit Service 4684c1
_GL_CXXALIASWARN (mempcpy);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef mempcpy
Packit Service 4684c1
# if HAVE_RAW_DECL_MEMPCPY
Packit Service 4684c1
_GL_WARN_ON_USE (mempcpy, "mempcpy is unportable - "
Packit Service 4684c1
                 "use gnulib module mempcpy for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Search backwards through a block for a byte (specified as an int).  */
Packit Service 4684c1
#if @GNULIB_MEMRCHR@
Packit Service 4684c1
# if ! @HAVE_DECL_MEMRCHR@
Packit Service 4684c1
_GL_FUNCDECL_SYS (memrchr, void *, (void const *, int, size_t)
Packit Service 4684c1
                                   _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
# endif
Packit Service 4684c1
  /* On some systems, this function is defined as an overloaded function:
Packit Service 4684c1
       extern "C++" { const void * std::memrchr (const void *, int, size_t); }
Packit Service 4684c1
       extern "C++" { void * std::memrchr (void *, int, size_t); }  */
Packit Service 4684c1
_GL_CXXALIAS_SYS_CAST2 (memrchr,
Packit Service 4684c1
                        void *, (void const *, int, size_t),
Packit Service 4684c1
                        void const *, (void const *, int, size_t));
Packit Service 4684c1
# if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
Packit Service 4684c1
     && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
Packit Service 4684c1
_GL_CXXALIASWARN1 (memrchr, void *, (void *, int, size_t));
Packit Service 4684c1
_GL_CXXALIASWARN1 (memrchr, void const *, (void const *, int, size_t));
Packit Service 4684c1
# else
Packit Service 4684c1
_GL_CXXALIASWARN (memrchr);
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef memrchr
Packit Service 4684c1
# if HAVE_RAW_DECL_MEMRCHR
Packit Service 4684c1
_GL_WARN_ON_USE (memrchr, "memrchr is unportable - "
Packit Service 4684c1
                 "use gnulib module memrchr for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Find the first occurrence of C in S.  More efficient than
Packit Service 4684c1
   memchr(S,C,N), at the expense of undefined behavior if C does not
Packit Service 4684c1
   occur within N bytes.  */
Packit Service 4684c1
#if @GNULIB_RAWMEMCHR@
Packit Service 4684c1
# if ! @HAVE_RAWMEMCHR@
Packit Service 4684c1
_GL_FUNCDECL_SYS (rawmemchr, void *, (void const *__s, int __c_in)
Packit Service 4684c1
                                     _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                     _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
# endif
Packit Service 4684c1
  /* On some systems, this function is defined as an overloaded function:
Packit Service 4684c1
       extern "C++" { const void * std::rawmemchr (const void *, int); }
Packit Service 4684c1
       extern "C++" { void * std::rawmemchr (void *, int); }  */
Packit Service 4684c1
_GL_CXXALIAS_SYS_CAST2 (rawmemchr,
Packit Service 4684c1
                        void *, (void const *__s, int __c_in),
Packit Service 4684c1
                        void const *, (void const *__s, int __c_in));
Packit Service 4684c1
# if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
Packit Service 4684c1
     && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
Packit Service 4684c1
_GL_CXXALIASWARN1 (rawmemchr, void *, (void *__s, int __c_in));
Packit Service 4684c1
_GL_CXXALIASWARN1 (rawmemchr, void const *, (void const *__s, int __c_in));
Packit Service 4684c1
# else
Packit Service 4684c1
_GL_CXXALIASWARN (rawmemchr);
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef rawmemchr
Packit Service 4684c1
# if HAVE_RAW_DECL_RAWMEMCHR
Packit Service 4684c1
_GL_WARN_ON_USE (rawmemchr, "rawmemchr is unportable - "
Packit Service 4684c1
                 "use gnulib module rawmemchr for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Copy SRC to DST, returning the address of the terminating '\0' in DST.  */
Packit Service 4684c1
#if @GNULIB_STPCPY@
Packit Service 4684c1
# if ! @HAVE_STPCPY@
Packit Service 4684c1
_GL_FUNCDECL_SYS (stpcpy, char *,
Packit Service 4684c1
                  (char *restrict __dst, char const *restrict __src)
Packit Service 4684c1
                  _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (stpcpy, char *,
Packit Service 4684c1
                  (char *restrict __dst, char const *restrict __src));
Packit Service 4684c1
_GL_CXXALIASWARN (stpcpy);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef stpcpy
Packit Service 4684c1
# if HAVE_RAW_DECL_STPCPY
Packit Service 4684c1
_GL_WARN_ON_USE (stpcpy, "stpcpy is unportable - "
Packit Service 4684c1
                 "use gnulib module stpcpy for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Copy no more than N bytes of SRC to DST, returning a pointer past the
Packit Service 4684c1
   last non-NUL byte written into DST.  */
Packit Service 4684c1
#if @GNULIB_STPNCPY@
Packit Service 4684c1
# if @REPLACE_STPNCPY@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   undef stpncpy
Packit Service 4684c1
#   define stpncpy rpl_stpncpy
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (stpncpy, char *,
Packit Service 4684c1
                  (char *restrict __dst, char const *restrict __src,
Packit Service 4684c1
                   size_t __n)
Packit Service 4684c1
                  _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (stpncpy, char *,
Packit Service 4684c1
                  (char *restrict __dst, char const *restrict __src,
Packit Service 4684c1
                   size_t __n));
Packit Service 4684c1
# else
Packit Service 4684c1
#  if ! @HAVE_STPNCPY@
Packit Service 4684c1
_GL_FUNCDECL_SYS (stpncpy, char *,
Packit Service 4684c1
                  (char *restrict __dst, char const *restrict __src,
Packit Service 4684c1
                   size_t __n)
Packit Service 4684c1
                  _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (stpncpy, char *,
Packit Service 4684c1
                  (char *restrict __dst, char const *restrict __src,
Packit Service 4684c1
                   size_t __n));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIASWARN (stpncpy);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef stpncpy
Packit Service 4684c1
# if HAVE_RAW_DECL_STPNCPY
Packit Service 4684c1
_GL_WARN_ON_USE (stpncpy, "stpncpy is unportable - "
Packit Service 4684c1
                 "use gnulib module stpncpy for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if defined GNULIB_POSIXCHECK
Packit Service 4684c1
/* strchr() does not work with multibyte strings if the locale encoding is
Packit Service 4684c1
   GB18030 and the character to be searched is a digit.  */
Packit Service 4684c1
# undef strchr
Packit Service 4684c1
/* Assume strchr is always declared.  */
Packit Service 4684c1
_GL_WARN_ON_USE_CXX (strchr, const char *, (const char *, int),
Packit Service 4684c1
                     "strchr cannot work correctly on character strings "
Packit Service 4684c1
                     "in some multibyte locales - "
Packit Service 4684c1
                     "use mbschr if you care about internationalization");
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Find the first occurrence of C in S or the final NUL byte.  */
Packit Service 4684c1
#if @GNULIB_STRCHRNUL@
Packit Service 4684c1
# if @REPLACE_STRCHRNUL@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   define strchrnul rpl_strchrnul
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (strchrnul, char *, (const char *__s, int __c_in)
Packit Service 4684c1
                                     _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                     _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (strchrnul, char *,
Packit Service 4684c1
                  (const char *str, int ch));
Packit Service 4684c1
# else
Packit Service 4684c1
#  if ! @HAVE_STRCHRNUL@
Packit Service 4684c1
_GL_FUNCDECL_SYS (strchrnul, char *, (char const *__s, int __c_in)
Packit Service 4684c1
                                     _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                     _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
#  endif
Packit Service 4684c1
  /* On some systems, this function is defined as an overloaded function:
Packit Service 4684c1
       extern "C++" { const char * std::strchrnul (const char *, int); }
Packit Service 4684c1
       extern "C++" { char * std::strchrnul (char *, int); }  */
Packit Service 4684c1
_GL_CXXALIAS_SYS_CAST2 (strchrnul,
Packit Service 4684c1
                        char *, (char const *__s, int __c_in),
Packit Service 4684c1
                        char const *, (char const *__s, int __c_in));
Packit Service 4684c1
# endif
Packit Service 4684c1
# if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
Packit Service 4684c1
     && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
Packit Service 4684c1
_GL_CXXALIASWARN1 (strchrnul, char *, (char *__s, int __c_in));
Packit Service 4684c1
_GL_CXXALIASWARN1 (strchrnul, char const *, (char const *__s, int __c_in));
Packit Service 4684c1
# else
Packit Service 4684c1
_GL_CXXALIASWARN (strchrnul);
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strchrnul
Packit Service 4684c1
# if HAVE_RAW_DECL_STRCHRNUL
Packit Service 4684c1
_GL_WARN_ON_USE (strchrnul, "strchrnul is unportable - "
Packit Service 4684c1
                 "use gnulib module strchrnul for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Duplicate S, returning an identical malloc'd string.  */
Packit Service 4684c1
#if @GNULIB_STRDUP@
Packit Service 4684c1
# if @REPLACE_STRDUP@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   undef strdup
Packit Service 4684c1
#   define strdup rpl_strdup
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (strdup, char *, (char const *__s) _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (strdup, char *, (char const *__s));
Packit Service 4684c1
# else
Packit Service 4684c1
#  if defined __cplusplus && defined GNULIB_NAMESPACE && defined strdup
Packit Service 4684c1
    /* strdup exists as a function and as a macro.  Get rid of the macro.  */
Packit Service 4684c1
#   undef strdup
Packit Service 4684c1
#  endif
Packit Service 4684c1
#  if !(@HAVE_DECL_STRDUP@ || defined strdup)
Packit Service 4684c1
_GL_FUNCDECL_SYS (strdup, char *, (char const *__s) _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (strdup, char *, (char const *__s));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIASWARN (strdup);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strdup
Packit Service 4684c1
# if HAVE_RAW_DECL_STRDUP
Packit Service 4684c1
_GL_WARN_ON_USE (strdup, "strdup is unportable - "
Packit Service 4684c1
                 "use gnulib module strdup for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Append no more than N characters from SRC onto DEST.  */
Packit Service 4684c1
#if @GNULIB_STRNCAT@
Packit Service 4684c1
# if @REPLACE_STRNCAT@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   undef strncat
Packit Service 4684c1
#   define strncat rpl_strncat
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (strncat, char *,
Packit Service 4684c1
                  (char *restrict dest, const char *restrict src, size_t n)
Packit Service 4684c1
                  _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (strncat, char *,
Packit Service 4684c1
                  (char *restrict dest, const char *restrict src, size_t n));
Packit Service 4684c1
# else
Packit Service 4684c1
_GL_CXXALIAS_SYS (strncat, char *,
Packit Service 4684c1
                  (char *restrict dest, const char *restrict src, size_t n));
Packit Service 4684c1
# endif
Packit Service 4684c1
# if __GLIBC__ >= 2
Packit Service 4684c1
_GL_CXXALIASWARN (strncat);
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strncat
Packit Service 4684c1
# if HAVE_RAW_DECL_STRNCAT
Packit Service 4684c1
_GL_WARN_ON_USE (strncat, "strncat is unportable - "
Packit Service 4684c1
                 "use gnulib module strncat for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Return a newly allocated copy of at most N bytes of STRING.  */
Packit Service 4684c1
#if @GNULIB_STRNDUP@
Packit Service 4684c1
# if @REPLACE_STRNDUP@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   undef strndup
Packit Service 4684c1
#   define strndup rpl_strndup
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (strndup, char *, (char const *__s, size_t __n)
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (strndup, char *, (char const *__s, size_t __n));
Packit Service 4684c1
# else
Packit Service 4684c1
#  if ! @HAVE_DECL_STRNDUP@
Packit Service 4684c1
_GL_FUNCDECL_SYS (strndup, char *, (char const *__s, size_t __n)
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (strndup, char *, (char const *__s, size_t __n));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIASWARN (strndup);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strndup
Packit Service 4684c1
# if HAVE_RAW_DECL_STRNDUP
Packit Service 4684c1
_GL_WARN_ON_USE (strndup, "strndup is unportable - "
Packit Service 4684c1
                 "use gnulib module strndup for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Find the length (number of bytes) of STRING, but scan at most
Packit Service 4684c1
   MAXLEN bytes.  If no '\0' terminator is found in that many bytes,
Packit Service 4684c1
   return MAXLEN.  */
Packit Service 4684c1
#if @GNULIB_STRNLEN@
Packit Service 4684c1
# if @REPLACE_STRNLEN@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   undef strnlen
Packit Service 4684c1
#   define strnlen rpl_strnlen
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (strnlen, size_t, (char const *__s, size_t __maxlen)
Packit Service 4684c1
                                   _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (strnlen, size_t, (char const *__s, size_t __maxlen));
Packit Service 4684c1
# else
Packit Service 4684c1
#  if ! @HAVE_DECL_STRNLEN@
Packit Service 4684c1
_GL_FUNCDECL_SYS (strnlen, size_t, (char const *__s, size_t __maxlen)
Packit Service 4684c1
                                   _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (strnlen, size_t, (char const *__s, size_t __maxlen));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIASWARN (strnlen);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strnlen
Packit Service 4684c1
# if HAVE_RAW_DECL_STRNLEN
Packit Service 4684c1
_GL_WARN_ON_USE (strnlen, "strnlen is unportable - "
Packit Service 4684c1
                 "use gnulib module strnlen for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if defined GNULIB_POSIXCHECK
Packit Service 4684c1
/* strcspn() assumes the second argument is a list of single-byte characters.
Packit Service 4684c1
   Even in this simple case, it does not work with multibyte strings if the
Packit Service 4684c1
   locale encoding is GB18030 and one of the characters to be searched is a
Packit Service 4684c1
   digit.  */
Packit Service 4684c1
# undef strcspn
Packit Service 4684c1
/* Assume strcspn is always declared.  */
Packit Service 4684c1
_GL_WARN_ON_USE (strcspn, "strcspn cannot work correctly on character strings "
Packit Service 4684c1
                 "in multibyte locales - "
Packit Service 4684c1
                 "use mbscspn if you care about internationalization");
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Find the first occurrence in S of any character in ACCEPT.  */
Packit Service 4684c1
#if @GNULIB_STRPBRK@
Packit Service 4684c1
# if ! @HAVE_STRPBRK@
Packit Service 4684c1
_GL_FUNCDECL_SYS (strpbrk, char *, (char const *__s, char const *__accept)
Packit Service 4684c1
                                   _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
# endif
Packit Service 4684c1
  /* On some systems, this function is defined as an overloaded function:
Packit Service 4684c1
       extern "C" { const char * strpbrk (const char *, const char *); }
Packit Service 4684c1
       extern "C++" { char * strpbrk (char *, const char *); }  */
Packit Service 4684c1
_GL_CXXALIAS_SYS_CAST2 (strpbrk,
Packit Service 4684c1
                        char *, (char const *__s, char const *__accept),
Packit Service 4684c1
                        const char *, (char const *__s, char const *__accept));
Packit Service 4684c1
# if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
Packit Service 4684c1
     && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
Packit Service 4684c1
_GL_CXXALIASWARN1 (strpbrk, char *, (char *__s, char const *__accept));
Packit Service 4684c1
_GL_CXXALIASWARN1 (strpbrk, char const *,
Packit Service 4684c1
                   (char const *__s, char const *__accept));
Packit Service 4684c1
# elif __GLIBC__ >= 2
Packit Service 4684c1
_GL_CXXALIASWARN (strpbrk);
Packit Service 4684c1
# endif
Packit Service 4684c1
# if defined GNULIB_POSIXCHECK
Packit Service 4684c1
/* strpbrk() assumes the second argument is a list of single-byte characters.
Packit Service 4684c1
   Even in this simple case, it does not work with multibyte strings if the
Packit Service 4684c1
   locale encoding is GB18030 and one of the characters to be searched is a
Packit Service 4684c1
   digit.  */
Packit Service 4684c1
#  undef strpbrk
Packit Service 4684c1
_GL_WARN_ON_USE_CXX (strpbrk, const char *, (const char *, const char *),
Packit Service 4684c1
                     "strpbrk cannot work correctly on character strings "
Packit Service 4684c1
                     "in multibyte locales - "
Packit Service 4684c1
                     "use mbspbrk if you care about internationalization");
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strpbrk
Packit Service 4684c1
# if HAVE_RAW_DECL_STRPBRK
Packit Service 4684c1
_GL_WARN_ON_USE_CXX (strpbrk, const char *, (const char *, const char *),
Packit Service 4684c1
                     "strpbrk is unportable - "
Packit Service 4684c1
                     "use gnulib module strpbrk for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if defined GNULIB_POSIXCHECK
Packit Service 4684c1
/* strspn() assumes the second argument is a list of single-byte characters.
Packit Service 4684c1
   Even in this simple case, it cannot work with multibyte strings.  */
Packit Service 4684c1
# undef strspn
Packit Service 4684c1
/* Assume strspn is always declared.  */
Packit Service 4684c1
_GL_WARN_ON_USE (strspn, "strspn cannot work correctly on character strings "
Packit Service 4684c1
                 "in multibyte locales - "
Packit Service 4684c1
                 "use mbsspn if you care about internationalization");
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if defined GNULIB_POSIXCHECK
Packit Service 4684c1
/* strrchr() does not work with multibyte strings if the locale encoding is
Packit Service 4684c1
   GB18030 and the character to be searched is a digit.  */
Packit Service 4684c1
# undef strrchr
Packit Service 4684c1
/* Assume strrchr is always declared.  */
Packit Service 4684c1
_GL_WARN_ON_USE_CXX (strrchr, const char *, (const char *, int),
Packit Service 4684c1
                     "strrchr cannot work correctly on character strings "
Packit Service 4684c1
                     "in some multibyte locales - "
Packit Service 4684c1
                     "use mbsrchr if you care about internationalization");
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Search the next delimiter (char listed in DELIM) starting at *STRINGP.
Packit Service 4684c1
   If one is found, overwrite it with a NUL, and advance *STRINGP
Packit Service 4684c1
   to point to the next char after it.  Otherwise, set *STRINGP to NULL.
Packit Service 4684c1
   If *STRINGP was already NULL, nothing happens.
Packit Service 4684c1
   Return the old value of *STRINGP.
Packit Service 4684c1
Packit Service 4684c1
   This is a variant of strtok() that is multithread-safe and supports
Packit Service 4684c1
   empty fields.
Packit Service 4684c1
Packit Service 4684c1
   Caveat: It modifies the original string.
Packit Service 4684c1
   Caveat: These functions cannot be used on constant strings.
Packit Service 4684c1
   Caveat: The identity of the delimiting character is lost.
Packit Service 4684c1
   Caveat: It doesn't work with multibyte strings unless all of the delimiter
Packit Service 4684c1
           characters are ASCII characters < 0x30.
Packit Service 4684c1
Packit Service 4684c1
   See also strtok_r().  */
Packit Service 4684c1
#if @GNULIB_STRSEP@
Packit Service 4684c1
# if ! @HAVE_STRSEP@
Packit Service 4684c1
_GL_FUNCDECL_SYS (strsep, char *,
Packit Service 4684c1
                  (char **restrict __stringp, char const *restrict __delim)
Packit Service 4684c1
                  _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (strsep, char *,
Packit Service 4684c1
                  (char **restrict __stringp, char const *restrict __delim));
Packit Service 4684c1
_GL_CXXALIASWARN (strsep);
Packit Service 4684c1
# if defined GNULIB_POSIXCHECK
Packit Service 4684c1
#  undef strsep
Packit Service 4684c1
_GL_WARN_ON_USE (strsep, "strsep cannot work correctly on character strings "
Packit Service 4684c1
                 "in multibyte locales - "
Packit Service 4684c1
                 "use mbssep if you care about internationalization");
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strsep
Packit Service 4684c1
# if HAVE_RAW_DECL_STRSEP
Packit Service 4684c1
_GL_WARN_ON_USE (strsep, "strsep is unportable - "
Packit Service 4684c1
                 "use gnulib module strsep for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_STRSTR@
Packit Service 4684c1
# if @REPLACE_STRSTR@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   define strstr rpl_strstr
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (strstr, char *, (const char *haystack, const char *needle)
Packit Service 4684c1
                                  _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                  _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (strstr, char *, (const char *haystack, const char *needle));
Packit Service 4684c1
# else
Packit Service 4684c1
  /* On some systems, this function is defined as an overloaded function:
Packit Service 4684c1
       extern "C++" { const char * strstr (const char *, const char *); }
Packit Service 4684c1
       extern "C++" { char * strstr (char *, const char *); }  */
Packit Service 4684c1
_GL_CXXALIAS_SYS_CAST2 (strstr,
Packit Service 4684c1
                        char *, (const char *haystack, const char *needle),
Packit Service 4684c1
                        const char *, (const char *haystack, const char *needle));
Packit Service 4684c1
# endif
Packit Service 4684c1
# if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
Packit Service 4684c1
     && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
Packit Service 4684c1
_GL_CXXALIASWARN1 (strstr, char *, (char *haystack, const char *needle));
Packit Service 4684c1
_GL_CXXALIASWARN1 (strstr, const char *,
Packit Service 4684c1
                   (const char *haystack, const char *needle));
Packit Service 4684c1
# elif __GLIBC__ >= 2
Packit Service 4684c1
_GL_CXXALIASWARN (strstr);
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
/* strstr() does not work with multibyte strings if the locale encoding is
Packit Service 4684c1
   different from UTF-8:
Packit Service 4684c1
   POSIX says that it operates on "strings", and "string" in POSIX is defined
Packit Service 4684c1
   as a sequence of bytes, not of characters.  */
Packit Service 4684c1
# undef strstr
Packit Service 4684c1
/* Assume strstr is always declared.  */
Packit Service 4684c1
_GL_WARN_ON_USE (strstr, "strstr is quadratic on many systems, and cannot "
Packit Service 4684c1
                 "work correctly on character strings in most "
Packit Service 4684c1
                 "multibyte locales - "
Packit Service 4684c1
                 "use mbsstr if you care about internationalization, "
Packit Service 4684c1
                 "or use strstr if you care about speed");
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Find the first occurrence of NEEDLE in HAYSTACK, using case-insensitive
Packit Service 4684c1
   comparison.  */
Packit Service 4684c1
#if @GNULIB_STRCASESTR@
Packit Service 4684c1
# if @REPLACE_STRCASESTR@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   define strcasestr rpl_strcasestr
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (strcasestr, char *,
Packit Service 4684c1
                  (const char *haystack, const char *needle)
Packit Service 4684c1
                  _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                  _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (strcasestr, char *,
Packit Service 4684c1
                  (const char *haystack, const char *needle));
Packit Service 4684c1
# else
Packit Service 4684c1
#  if ! @HAVE_STRCASESTR@
Packit Service 4684c1
_GL_FUNCDECL_SYS (strcasestr, char *,
Packit Service 4684c1
                  (const char *haystack, const char *needle)
Packit Service 4684c1
                  _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                  _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
#  endif
Packit Service 4684c1
  /* On some systems, this function is defined as an overloaded function:
Packit Service 4684c1
       extern "C++" { const char * strcasestr (const char *, const char *); }
Packit Service 4684c1
       extern "C++" { char * strcasestr (char *, const char *); }  */
Packit Service 4684c1
_GL_CXXALIAS_SYS_CAST2 (strcasestr,
Packit Service 4684c1
                        char *, (const char *haystack, const char *needle),
Packit Service 4684c1
                        const char *, (const char *haystack, const char *needle));
Packit Service 4684c1
# endif
Packit Service 4684c1
# if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
Packit Service 4684c1
     && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
Packit Service 4684c1
_GL_CXXALIASWARN1 (strcasestr, char *, (char *haystack, const char *needle));
Packit Service 4684c1
_GL_CXXALIASWARN1 (strcasestr, const char *,
Packit Service 4684c1
                   (const char *haystack, const char *needle));
Packit Service 4684c1
# else
Packit Service 4684c1
_GL_CXXALIASWARN (strcasestr);
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
/* strcasestr() does not work with multibyte strings:
Packit Service 4684c1
   It is a glibc extension, and glibc implements it only for unibyte
Packit Service 4684c1
   locales.  */
Packit Service 4684c1
# undef strcasestr
Packit Service 4684c1
# if HAVE_RAW_DECL_STRCASESTR
Packit Service 4684c1
_GL_WARN_ON_USE (strcasestr, "strcasestr does work correctly on character "
Packit Service 4684c1
                 "strings in multibyte locales - "
Packit Service 4684c1
                 "use mbscasestr if you care about "
Packit Service 4684c1
                 "internationalization, or use c-strcasestr if you want "
Packit Service 4684c1
                 "a locale independent function");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Parse S into tokens separated by characters in DELIM.
Packit Service 4684c1
   If S is NULL, the saved pointer in SAVE_PTR is used as
Packit Service 4684c1
   the next starting point.  For example:
Packit Service 4684c1
        char s[] = "-abc-=-def";
Packit Service 4684c1
        char *sp;
Packit Service 4684c1
        x = strtok_r(s, "-", &sp);      // x = "abc", sp = "=-def"
Packit Service 4684c1
        x = strtok_r(NULL, "-=", &sp);  // x = "def", sp = NULL
Packit Service 4684c1
        x = strtok_r(NULL, "=", &sp);   // x = NULL
Packit Service 4684c1
                // s = "abc\0-def\0"
Packit Service 4684c1
Packit Service 4684c1
   This is a variant of strtok() that is multithread-safe.
Packit Service 4684c1
Packit Service 4684c1
   For the POSIX documentation for this function, see:
Packit Service 4684c1
   https://pubs.opengroup.org/onlinepubs/9699919799/functions/strtok.html
Packit Service 4684c1
Packit Service 4684c1
   Caveat: It modifies the original string.
Packit Service 4684c1
   Caveat: These functions cannot be used on constant strings.
Packit Service 4684c1
   Caveat: The identity of the delimiting character is lost.
Packit Service 4684c1
   Caveat: It doesn't work with multibyte strings unless all of the delimiter
Packit Service 4684c1
           characters are ASCII characters < 0x30.
Packit Service 4684c1
Packit Service 4684c1
   See also strsep().  */
Packit Service 4684c1
#if @GNULIB_STRTOK_R@
Packit Service 4684c1
# if @REPLACE_STRTOK_R@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   undef strtok_r
Packit Service 4684c1
#   define strtok_r rpl_strtok_r
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (strtok_r, char *,
Packit Service 4684c1
                  (char *restrict s, char const *restrict delim,
Packit Service 4684c1
                   char **restrict save_ptr)
Packit Service 4684c1
                  _GL_ARG_NONNULL ((2, 3)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (strtok_r, char *,
Packit Service 4684c1
                  (char *restrict s, char const *restrict delim,
Packit Service 4684c1
                   char **restrict save_ptr));
Packit Service 4684c1
# else
Packit Service 4684c1
#  if @UNDEFINE_STRTOK_R@ || defined GNULIB_POSIXCHECK
Packit Service 4684c1
#   undef strtok_r
Packit Service 4684c1
#  endif
Packit Service 4684c1
#  if ! @HAVE_DECL_STRTOK_R@
Packit Service 4684c1
_GL_FUNCDECL_SYS (strtok_r, char *,
Packit Service 4684c1
                  (char *restrict s, char const *restrict delim,
Packit Service 4684c1
                   char **restrict save_ptr)
Packit Service 4684c1
                  _GL_ARG_NONNULL ((2, 3)));
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (strtok_r, char *,
Packit Service 4684c1
                  (char *restrict s, char const *restrict delim,
Packit Service 4684c1
                   char **restrict save_ptr));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIASWARN (strtok_r);
Packit Service 4684c1
# if defined GNULIB_POSIXCHECK
Packit Service 4684c1
_GL_WARN_ON_USE (strtok_r, "strtok_r cannot work correctly on character "
Packit Service 4684c1
                 "strings in multibyte locales - "
Packit Service 4684c1
                 "use mbstok_r if you care about internationalization");
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strtok_r
Packit Service 4684c1
# if HAVE_RAW_DECL_STRTOK_R
Packit Service 4684c1
_GL_WARN_ON_USE (strtok_r, "strtok_r is unportable - "
Packit Service 4684c1
                 "use gnulib module strtok_r for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
Packit Service 4684c1
/* The following functions are not specified by POSIX.  They are gnulib
Packit Service 4684c1
   extensions.  */
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSLEN@
Packit Service 4684c1
/* Return the number of multibyte characters in the character string STRING.
Packit Service 4684c1
   This considers multibyte characters, unlike strlen, which counts bytes.  */
Packit Service 4684c1
# ifdef __MirBSD__  /* MirBSD defines mbslen as a macro.  Override it.  */
Packit Service 4684c1
#  undef mbslen
Packit Service 4684c1
# endif
Packit Service 4684c1
# if @HAVE_MBSLEN@  /* AIX, OSF/1, MirBSD define mbslen already in libc.  */
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   define mbslen rpl_mbslen
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (mbslen, size_t, (const char *string)
Packit Service 4684c1
                                  _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                  _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (mbslen, size_t, (const char *string));
Packit Service 4684c1
# else
Packit Service 4684c1
_GL_FUNCDECL_SYS (mbslen, size_t, (const char *string)
Packit Service 4684c1
                                  _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                  _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
_GL_CXXALIAS_SYS (mbslen, size_t, (const char *string));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIASWARN (mbslen);
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSNLEN@
Packit Service 4684c1
/* Return the number of multibyte characters in the character string starting
Packit Service 4684c1
   at STRING and ending at STRING + LEN.  */
Packit Service 4684c1
_GL_EXTERN_C size_t mbsnlen (const char *string, size_t len)
Packit Service 4684c1
     _GL_ATTRIBUTE_PURE
Packit Service 4684c1
     _GL_ARG_NONNULL ((1));
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSCHR@
Packit Service 4684c1
/* Locate the first single-byte character C in the character string STRING,
Packit Service 4684c1
   and return a pointer to it.  Return NULL if C is not found in STRING.
Packit Service 4684c1
   Unlike strchr(), this function works correctly in multibyte locales with
Packit Service 4684c1
   encodings such as GB18030.  */
Packit Service 4684c1
# if defined __hpux
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   define mbschr rpl_mbschr /* avoid collision with HP-UX function */
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (mbschr, char *, (const char *string, int c)
Packit Service 4684c1
                                  _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                  _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (mbschr, char *, (const char *string, int c));
Packit Service 4684c1
# else
Packit Service 4684c1
_GL_FUNCDECL_SYS (mbschr, char *, (const char *string, int c)
Packit Service 4684c1
                                  _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                  _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
_GL_CXXALIAS_SYS (mbschr, char *, (const char *string, int c));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIASWARN (mbschr);
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSRCHR@
Packit Service 4684c1
/* Locate the last single-byte character C in the character string STRING,
Packit Service 4684c1
   and return a pointer to it.  Return NULL if C is not found in STRING.
Packit Service 4684c1
   Unlike strrchr(), this function works correctly in multibyte locales with
Packit Service 4684c1
   encodings such as GB18030.  */
Packit Service 4684c1
# if defined __hpux || defined __INTERIX
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   define mbsrchr rpl_mbsrchr /* avoid collision with system function */
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (mbsrchr, char *, (const char *string, int c)
Packit Service 4684c1
                                   _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (mbsrchr, char *, (const char *string, int c));
Packit Service 4684c1
# else
Packit Service 4684c1
_GL_FUNCDECL_SYS (mbsrchr, char *, (const char *string, int c)
Packit Service 4684c1
                                   _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((1)));
Packit Service 4684c1
_GL_CXXALIAS_SYS (mbsrchr, char *, (const char *string, int c));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIASWARN (mbsrchr);
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSSTR@
Packit Service 4684c1
/* Find the first occurrence of the character string NEEDLE in the character
Packit Service 4684c1
   string HAYSTACK.  Return NULL if NEEDLE is not found in HAYSTACK.
Packit Service 4684c1
   Unlike strstr(), this function works correctly in multibyte locales with
Packit Service 4684c1
   encodings different from UTF-8.  */
Packit Service 4684c1
_GL_EXTERN_C char * mbsstr (const char *haystack, const char *needle)
Packit Service 4684c1
     _GL_ATTRIBUTE_PURE
Packit Service 4684c1
     _GL_ARG_NONNULL ((1, 2));
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSCASECMP@
Packit Service 4684c1
/* Compare the character strings S1 and S2, ignoring case, returning less than,
Packit Service 4684c1
   equal to or greater than zero if S1 is lexicographically less than, equal to
Packit Service 4684c1
   or greater than S2.
Packit Service 4684c1
   Note: This function may, in multibyte locales, return 0 for strings of
Packit Service 4684c1
   different lengths!
Packit Service 4684c1
   Unlike strcasecmp(), this function works correctly in multibyte locales.  */
Packit Service 4684c1
_GL_EXTERN_C int mbscasecmp (const char *s1, const char *s2)
Packit Service 4684c1
     _GL_ATTRIBUTE_PURE
Packit Service 4684c1
     _GL_ARG_NONNULL ((1, 2));
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSNCASECMP@
Packit Service 4684c1
/* Compare the initial segment of the character string S1 consisting of at most
Packit Service 4684c1
   N characters with the initial segment of the character string S2 consisting
Packit Service 4684c1
   of at most N characters, ignoring case, returning less than, equal to or
Packit Service 4684c1
   greater than zero if the initial segment of S1 is lexicographically less
Packit Service 4684c1
   than, equal to or greater than the initial segment of S2.
Packit Service 4684c1
   Note: This function may, in multibyte locales, return 0 for initial segments
Packit Service 4684c1
   of different lengths!
Packit Service 4684c1
   Unlike strncasecmp(), this function works correctly in multibyte locales.
Packit Service 4684c1
   But beware that N is not a byte count but a character count!  */
Packit Service 4684c1
_GL_EXTERN_C int mbsncasecmp (const char *s1, const char *s2, size_t n)
Packit Service 4684c1
     _GL_ATTRIBUTE_PURE
Packit Service 4684c1
     _GL_ARG_NONNULL ((1, 2));
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSPCASECMP@
Packit Service 4684c1
/* Compare the initial segment of the character string STRING consisting of
Packit Service 4684c1
   at most mbslen (PREFIX) characters with the character string PREFIX,
Packit Service 4684c1
   ignoring case.  If the two match, return a pointer to the first byte
Packit Service 4684c1
   after this prefix in STRING.  Otherwise, return NULL.
Packit Service 4684c1
   Note: This function may, in multibyte locales, return non-NULL if STRING
Packit Service 4684c1
   is of smaller length than PREFIX!
Packit Service 4684c1
   Unlike strncasecmp(), this function works correctly in multibyte
Packit Service 4684c1
   locales.  */
Packit Service 4684c1
_GL_EXTERN_C char * mbspcasecmp (const char *string, const char *prefix)
Packit Service 4684c1
     _GL_ATTRIBUTE_PURE
Packit Service 4684c1
     _GL_ARG_NONNULL ((1, 2));
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSCASESTR@
Packit Service 4684c1
/* Find the first occurrence of the character string NEEDLE in the character
Packit Service 4684c1
   string HAYSTACK, using case-insensitive comparison.
Packit Service 4684c1
   Note: This function may, in multibyte locales, return success even if
Packit Service 4684c1
   strlen (haystack) < strlen (needle) !
Packit Service 4684c1
   Unlike strcasestr(), this function works correctly in multibyte locales.  */
Packit Service 4684c1
_GL_EXTERN_C char * mbscasestr (const char *haystack, const char *needle)
Packit Service 4684c1
     _GL_ATTRIBUTE_PURE
Packit Service 4684c1
     _GL_ARG_NONNULL ((1, 2));
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSCSPN@
Packit Service 4684c1
/* Find the first occurrence in the character string STRING of any character
Packit Service 4684c1
   in the character string ACCEPT.  Return the number of bytes from the
Packit Service 4684c1
   beginning of the string to this occurrence, or to the end of the string
Packit Service 4684c1
   if none exists.
Packit Service 4684c1
   Unlike strcspn(), this function works correctly in multibyte locales.  */
Packit Service 4684c1
_GL_EXTERN_C size_t mbscspn (const char *string, const char *accept)
Packit Service 4684c1
     _GL_ATTRIBUTE_PURE
Packit Service 4684c1
     _GL_ARG_NONNULL ((1, 2));
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSPBRK@
Packit Service 4684c1
/* Find the first occurrence in the character string STRING of any character
Packit Service 4684c1
   in the character string ACCEPT.  Return the pointer to it, or NULL if none
Packit Service 4684c1
   exists.
Packit Service 4684c1
   Unlike strpbrk(), this function works correctly in multibyte locales.  */
Packit Service 4684c1
# if defined __hpux
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   define mbspbrk rpl_mbspbrk /* avoid collision with HP-UX function */
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (mbspbrk, char *, (const char *string, const char *accept)
Packit Service 4684c1
                                   _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (mbspbrk, char *, (const char *string, const char *accept));
Packit Service 4684c1
# else
Packit Service 4684c1
_GL_FUNCDECL_SYS (mbspbrk, char *, (const char *string, const char *accept)
Packit Service 4684c1
                                   _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
_GL_CXXALIAS_SYS (mbspbrk, char *, (const char *string, const char *accept));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIASWARN (mbspbrk);
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSSPN@
Packit Service 4684c1
/* Find the first occurrence in the character string STRING of any character
Packit Service 4684c1
   not in the character string REJECT.  Return the number of bytes from the
Packit Service 4684c1
   beginning of the string to this occurrence, or to the end of the string
Packit Service 4684c1
   if none exists.
Packit Service 4684c1
   Unlike strspn(), this function works correctly in multibyte locales.  */
Packit Service 4684c1
_GL_EXTERN_C size_t mbsspn (const char *string, const char *reject)
Packit Service 4684c1
     _GL_ATTRIBUTE_PURE
Packit Service 4684c1
     _GL_ARG_NONNULL ((1, 2));
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSSEP@
Packit Service 4684c1
/* Search the next delimiter (multibyte character listed in the character
Packit Service 4684c1
   string DELIM) starting at the character string *STRINGP.
Packit Service 4684c1
   If one is found, overwrite it with a NUL, and advance *STRINGP to point
Packit Service 4684c1
   to the next multibyte character after it.  Otherwise, set *STRINGP to NULL.
Packit Service 4684c1
   If *STRINGP was already NULL, nothing happens.
Packit Service 4684c1
   Return the old value of *STRINGP.
Packit Service 4684c1
Packit Service 4684c1
   This is a variant of mbstok_r() that supports empty fields.
Packit Service 4684c1
Packit Service 4684c1
   Caveat: It modifies the original string.
Packit Service 4684c1
   Caveat: These functions cannot be used on constant strings.
Packit Service 4684c1
   Caveat: The identity of the delimiting character is lost.
Packit Service 4684c1
Packit Service 4684c1
   See also mbstok_r().  */
Packit Service 4684c1
_GL_EXTERN_C char * mbssep (char **stringp, const char *delim)
Packit Service 4684c1
     _GL_ARG_NONNULL ((1, 2));
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_MBSTOK_R@
Packit Service 4684c1
/* Parse the character string STRING into tokens separated by characters in
Packit Service 4684c1
   the character string DELIM.
Packit Service 4684c1
   If STRING is NULL, the saved pointer in SAVE_PTR is used as
Packit Service 4684c1
   the next starting point.  For example:
Packit Service 4684c1
        char s[] = "-abc-=-def";
Packit Service 4684c1
        char *sp;
Packit Service 4684c1
        x = mbstok_r(s, "-", &sp);      // x = "abc", sp = "=-def"
Packit Service 4684c1
        x = mbstok_r(NULL, "-=", &sp);  // x = "def", sp = NULL
Packit Service 4684c1
        x = mbstok_r(NULL, "=", &sp);   // x = NULL
Packit Service 4684c1
                // s = "abc\0-def\0"
Packit Service 4684c1
Packit Service 4684c1
   Caveat: It modifies the original string.
Packit Service 4684c1
   Caveat: These functions cannot be used on constant strings.
Packit Service 4684c1
   Caveat: The identity of the delimiting character is lost.
Packit Service 4684c1
Packit Service 4684c1
   See also mbssep().  */
Packit Service 4684c1
_GL_EXTERN_C char * mbstok_r (char *restrict string, const char *delim,
Packit Service 4684c1
                              char **save_ptr)
Packit Service 4684c1
     _GL_ARG_NONNULL ((2, 3));
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Map any int, typically from errno, into an error message.  */
Packit Service 4684c1
#if @GNULIB_STRERROR@
Packit Service 4684c1
# if @REPLACE_STRERROR@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   undef strerror
Packit Service 4684c1
#   define strerror rpl_strerror
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (strerror, char *, (int));
Packit Service 4684c1
_GL_CXXALIAS_RPL (strerror, char *, (int));
Packit Service 4684c1
# else
Packit Service 4684c1
_GL_CXXALIAS_SYS (strerror, char *, (int));
Packit Service 4684c1
# endif
Packit Service 4684c1
# if __GLIBC__ >= 2
Packit Service 4684c1
_GL_CXXALIASWARN (strerror);
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strerror
Packit Service 4684c1
/* Assume strerror is always declared.  */
Packit Service 4684c1
_GL_WARN_ON_USE (strerror, "strerror is unportable - "
Packit Service 4684c1
                 "use gnulib module strerror to guarantee non-NULL result");
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
/* Map any int, typically from errno, into an error message.  Multithread-safe.
Packit Service 4684c1
   Uses the POSIX declaration, not the glibc declaration.  */
Packit Service 4684c1
#if @GNULIB_STRERROR_R@
Packit Service 4684c1
# if @REPLACE_STRERROR_R@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   undef strerror_r
Packit Service 4684c1
#   define strerror_r rpl_strerror_r
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (strerror_r, int, (int errnum, char *buf, size_t buflen)
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((2)));
Packit Service 4684c1
_GL_CXXALIAS_RPL (strerror_r, int, (int errnum, char *buf, size_t buflen));
Packit Service 4684c1
# else
Packit Service 4684c1
#  if !@HAVE_DECL_STRERROR_R@
Packit Service 4684c1
_GL_FUNCDECL_SYS (strerror_r, int, (int errnum, char *buf, size_t buflen)
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((2)));
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (strerror_r, int, (int errnum, char *buf, size_t buflen));
Packit Service 4684c1
# endif
Packit Service 4684c1
# if @HAVE_DECL_STRERROR_R@
Packit Service 4684c1
_GL_CXXALIASWARN (strerror_r);
Packit Service 4684c1
# endif
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strerror_r
Packit Service 4684c1
# if HAVE_RAW_DECL_STRERROR_R
Packit Service 4684c1
_GL_WARN_ON_USE (strerror_r, "strerror_r is unportable - "
Packit Service 4684c1
                 "use gnulib module strerror_r-posix for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_STRSIGNAL@
Packit Service 4684c1
# if @REPLACE_STRSIGNAL@
Packit Service 4684c1
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service 4684c1
#   define strsignal rpl_strsignal
Packit Service 4684c1
#  endif
Packit Service 4684c1
_GL_FUNCDECL_RPL (strsignal, char *, (int __sig));
Packit Service 4684c1
_GL_CXXALIAS_RPL (strsignal, char *, (int __sig));
Packit Service 4684c1
# else
Packit Service 4684c1
#  if ! @HAVE_DECL_STRSIGNAL@
Packit Service 4684c1
_GL_FUNCDECL_SYS (strsignal, char *, (int __sig));
Packit Service 4684c1
#  endif
Packit Service 4684c1
/* Need to cast, because on Cygwin 1.5.x systems, the return type is
Packit Service 4684c1
   'const char *'.  */
Packit Service 4684c1
_GL_CXXALIAS_SYS_CAST (strsignal, char *, (int __sig));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIASWARN (strsignal);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strsignal
Packit Service 4684c1
# if HAVE_RAW_DECL_STRSIGNAL
Packit Service 4684c1
_GL_WARN_ON_USE (strsignal, "strsignal is unportable - "
Packit Service 4684c1
                 "use gnulib module strsignal for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
#if @GNULIB_STRVERSCMP@
Packit Service 4684c1
# if !@HAVE_STRVERSCMP@
Packit Service 4684c1
_GL_FUNCDECL_SYS (strverscmp, int, (const char *, const char *)
Packit Service 4684c1
                                   _GL_ATTRIBUTE_PURE
Packit Service 4684c1
                                   _GL_ARG_NONNULL ((1, 2)));
Packit Service 4684c1
# endif
Packit Service 4684c1
_GL_CXXALIAS_SYS (strverscmp, int, (const char *, const char *));
Packit Service 4684c1
_GL_CXXALIASWARN (strverscmp);
Packit Service 4684c1
#elif defined GNULIB_POSIXCHECK
Packit Service 4684c1
# undef strverscmp
Packit Service 4684c1
# if HAVE_RAW_DECL_STRVERSCMP
Packit Service 4684c1
_GL_WARN_ON_USE (strverscmp, "strverscmp is unportable - "
Packit Service 4684c1
                 "use gnulib module strverscmp for portability");
Packit Service 4684c1
# endif
Packit Service 4684c1
#endif
Packit Service 4684c1
Packit Service 4684c1
Packit Service 4684c1
#endif /* _@GUARD_PREFIX@_STRING_H */
Packit Service 4684c1
#endif /* _@GUARD_PREFIX@_STRING_H */
Packit Service 4684c1
#endif