1 /* This file is automatically generated.  DO NOT EDIT! */
2 /* Generated from: NetBSD: mknative-gdb,v 1.12 2020/09/17 16:54:31 christos Exp  */
3 /* Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp  */
4 
5 /* DO NOT EDIT! GENERATED AUTOMATICALLY! */
6 /* A substitute for ISO C99 <wchar.h>, for platforms that have issues.
7 
8    Copyright (C) 2007-2020 Free Software Foundation, Inc.
9 
10    This program is free software; you can redistribute it and/or modify
11    it under the terms of the GNU General Public License as published by
12    the Free Software Foundation; either version 3, or (at your option)
13    any later version.
14 
15    This program is distributed in the hope that it will be useful,
16    but WITHOUT ANY WARRANTY; without even the implied warranty of
17    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18    GNU General Public License for more details.
19 
20    You should have received a copy of the GNU General Public License
21    along with this program; if not, see <https://www.gnu.org/licenses/>.  */
22 
23 /* Written by Eric Blake.  */
24 
25 /*
26  * ISO C 99 <wchar.h> for platforms that have issues.
27  * <https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/wchar.h.html>
28  *
29  * For now, this just ensures proper prerequisite inclusion order and
30  * the declaration of wcwidth().
31  */
32 
33 #if __GNUC__ >= 3
34 #pragma GCC system_header
35 #endif
36 
37 
38 #if (((defined __need_mbstate_t || defined __need_wint_t)               \
39       && !defined __MINGW32__)                                          \
40      || (defined __hpux                                                 \
41          && ((defined _INTTYPES_INCLUDED                                \
42               && !defined _GL_FINISHED_INCLUDING_SYSTEM_INTTYPES_H)     \
43              || defined _GL_JUST_INCLUDE_SYSTEM_WCHAR_H))               \
44      || (defined __MINGW32__ && defined __STRING_H_SOURCED__)           \
45      || defined _GL_ALREADY_INCLUDING_WCHAR_H)
46 /* Special invocation convention:
47    - Inside glibc and uClibc header files, but not MinGW.
48    - On HP-UX 11.00 we have a sequence of nested includes
49      <wchar.h> -> <stdlib.h> -> <stdint.h>, and the latter includes <wchar.h>,
50      once indirectly <stdint.h> -> <sys/types.h> -> <inttypes.h> -> <wchar.h>
51      and once directly.  In both situations 'wint_t' is not yet defined,
52      therefore we cannot provide the function overrides; instead include only
53      the system's <wchar.h>.
54    - With MinGW 3.22, when <string.h> includes <wchar.h>, only some part of
55      <wchar.h> is actually processed, and that doesn't include 'mbstate_t'.
56    - On IRIX 6.5, similarly, we have an include <wchar.h> -> <wctype.h>, and
57      the latter includes <wchar.h>.  But here, we have no way to detect whether
58      <wctype.h> is completely included or is still being included.  */
59 
60 #include_next <wchar.h>
61 
62 #else
63 /* Normal invocation convention.  */
64 
65 #ifndef _GL_WCHAR_H
66 
67 #define _GL_ALREADY_INCLUDING_WCHAR_H
68 
69 #if 0
70 # include <features.h> /* for __GLIBC__ */
71 #endif
72 
73 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
74    <wchar.h>.
75    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
76    included before <wchar.h>.
77    In some builds of uClibc, <wchar.h> is nonexistent and wchar_t is defined
78    by <stddef.h>.
79    But avoid namespace pollution on glibc systems.  */
80 #if !(defined __GLIBC__ && !defined __UCLIBC__)
81 # include <stddef.h>
82 #endif
83 #ifndef __GLIBC__
84 # include <stdio.h>
85 # include <time.h>
86 #endif
87 
88 /* Include the original <wchar.h> if it exists.
89    Some builds of uClibc lack it.  */
90 /* The include_next requires a split double-inclusion guard.  */
91 #if 1
92 # include_next <wchar.h>
93 #endif
94 
95 #undef _GL_ALREADY_INCLUDING_WCHAR_H
96 
97 #ifndef _GL_WCHAR_H
98 #define _GL_WCHAR_H
99 
100 /* The __attribute__ feature is available in gcc versions 2.5 and later.
101    The attribute __pure__ was added in gcc 2.96.  */
102 #ifndef _GL_ATTRIBUTE_PURE
103 # if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 96)
104 #  define _GL_ATTRIBUTE_PURE __attribute__ ((__pure__))
105 # else
106 #  define _GL_ATTRIBUTE_PURE /* empty */
107 # endif
108 #endif
109 
110 /* The definitions of _GL_FUNCDECL_RPL etc. are copied here.  */
111 /* C++ compatible function declaration macros.
112    Copyright (C) 2010-2020 Free Software Foundation, Inc.
113 
114    This program is free software: you can redistribute it and/or modify it
115    under the terms of the GNU General Public License as published
116    by the Free Software Foundation; either version 3 of the License, or
117    (at your option) any later version.
118 
119    This program is distributed in the hope that it will be useful,
120    but WITHOUT ANY WARRANTY; without even the implied warranty of
121    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
122    General Public License for more details.
123 
124    You should have received a copy of the GNU General Public License
125    along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
126 
127 #ifndef _GL_CXXDEFS_H
128 #define _GL_CXXDEFS_H
129 
130 /* Begin/end the GNULIB_NAMESPACE namespace.  */
131 #if defined __cplusplus && defined GNULIB_NAMESPACE
132 # define _GL_BEGIN_NAMESPACE namespace GNULIB_NAMESPACE {
133 # define _GL_END_NAMESPACE }
134 #else
135 # define _GL_BEGIN_NAMESPACE
136 # define _GL_END_NAMESPACE
137 #endif
138 
139 /* The three most frequent use cases of these macros are:
140 
141    * For providing a substitute for a function that is missing on some
142      platforms, but is declared and works fine on the platforms on which
143      it exists:
144 
145        #if @GNULIB_FOO@
146        # if !@HAVE_FOO@
147        _GL_FUNCDECL_SYS (foo, ...);
148        # endif
149        _GL_CXXALIAS_SYS (foo, ...);
150        _GL_CXXALIASWARN (foo);
151        #elif defined GNULIB_POSIXCHECK
152        ...
153        #endif
154 
155    * For providing a replacement for a function that exists on all platforms,
156      but is broken/insufficient and needs to be replaced on some platforms:
157 
158        #if @GNULIB_FOO@
159        # if @REPLACE_FOO@
160        #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
161        #   undef foo
162        #   define foo rpl_foo
163        #  endif
164        _GL_FUNCDECL_RPL (foo, ...);
165        _GL_CXXALIAS_RPL (foo, ...);
166        # else
167        _GL_CXXALIAS_SYS (foo, ...);
168        # endif
169        _GL_CXXALIASWARN (foo);
170        #elif defined GNULIB_POSIXCHECK
171        ...
172        #endif
173 
174    * For providing a replacement for a function that exists on some platforms
175      but is broken/insufficient and needs to be replaced on some of them and
176      is additionally either missing or undeclared on some other platforms:
177 
178        #if @GNULIB_FOO@
179        # if @REPLACE_FOO@
180        #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
181        #   undef foo
182        #   define foo rpl_foo
183        #  endif
184        _GL_FUNCDECL_RPL (foo, ...);
185        _GL_CXXALIAS_RPL (foo, ...);
186        # else
187        #  if !@HAVE_FOO@   or   if !@HAVE_DECL_FOO@
188        _GL_FUNCDECL_SYS (foo, ...);
189        #  endif
190        _GL_CXXALIAS_SYS (foo, ...);
191        # endif
192        _GL_CXXALIASWARN (foo);
193        #elif defined GNULIB_POSIXCHECK
194        ...
195        #endif
196 */
197 
198 /* _GL_EXTERN_C declaration;
199    performs the declaration with C linkage.  */
200 #if defined __cplusplus
201 # define _GL_EXTERN_C extern "C"
202 #else
203 # define _GL_EXTERN_C extern
204 #endif
205 
206 /* _GL_FUNCDECL_RPL (func, rettype, parameters_and_attributes);
207    declares a replacement function, named rpl_func, with the given prototype,
208    consisting of return type, parameters, and attributes.
209    Example:
210      _GL_FUNCDECL_RPL (open, int, (const char *filename, int flags, ...)
211                                   _GL_ARG_NONNULL ((1)));
212  */
213 #define _GL_FUNCDECL_RPL(func,rettype,parameters_and_attributes) \
214   _GL_FUNCDECL_RPL_1 (rpl_##func, rettype, parameters_and_attributes)
215 #define _GL_FUNCDECL_RPL_1(rpl_func,rettype,parameters_and_attributes) \
216   _GL_EXTERN_C rettype rpl_func parameters_and_attributes
217 
218 /* _GL_FUNCDECL_SYS (func, rettype, parameters_and_attributes);
219    declares the system function, named func, with the given prototype,
220    consisting of return type, parameters, and attributes.
221    Example:
222      _GL_FUNCDECL_SYS (open, int, (const char *filename, int flags, ...)
223                                   _GL_ARG_NONNULL ((1)));
224  */
225 #define _GL_FUNCDECL_SYS(func,rettype,parameters_and_attributes) \
226   _GL_EXTERN_C rettype func parameters_and_attributes
227 
228 /* _GL_CXXALIAS_RPL (func, rettype, parameters);
229    declares a C++ alias called GNULIB_NAMESPACE::func
230    that redirects to rpl_func, if GNULIB_NAMESPACE is defined.
231    Example:
232      _GL_CXXALIAS_RPL (open, int, (const char *filename, int flags, ...));
233 
234    Wrapping rpl_func in an object with an inline conversion operator
235    avoids a reference to rpl_func unless GNULIB_NAMESPACE::func is
236    actually used in the program.  */
237 #define _GL_CXXALIAS_RPL(func,rettype,parameters) \
238   _GL_CXXALIAS_RPL_1 (func, rpl_##func, rettype, parameters)
239 #if defined __cplusplus && defined GNULIB_NAMESPACE
240 # define _GL_CXXALIAS_RPL_1(func,rpl_func,rettype,parameters) \
241     namespace GNULIB_NAMESPACE                                \
242     {                                                         \
243       static const struct _gl_ ## func ## _wrapper            \
244       {                                                       \
245         typedef rettype (*type) parameters;                   \
246                                                               \
247         inline operator type () const                         \
248         {                                                     \
249           return ::rpl_func;                                  \
250         }                                                     \
251       } func = {};                                            \
252     }                                                         \
253     _GL_EXTERN_C int _gl_cxxalias_dummy
254 #else
255 # define _GL_CXXALIAS_RPL_1(func,rpl_func,rettype,parameters) \
256     _GL_EXTERN_C int _gl_cxxalias_dummy
257 #endif
258 
259 /* _GL_CXXALIAS_RPL_CAST_1 (func, rpl_func, rettype, parameters);
260    is like  _GL_CXXALIAS_RPL_1 (func, rpl_func, rettype, parameters);
261    except that the C function rpl_func may have a slightly different
262    declaration.  A cast is used to silence the "invalid conversion" error
263    that would otherwise occur.  */
264 #if defined __cplusplus && defined GNULIB_NAMESPACE
265 # define _GL_CXXALIAS_RPL_CAST_1(func,rpl_func,rettype,parameters) \
266     namespace GNULIB_NAMESPACE                                     \
267     {                                                              \
268       static const struct _gl_ ## func ## _wrapper                 \
269       {                                                            \
270         typedef rettype (*type) parameters;                        \
271                                                                    \
272         inline operator type () const                              \
273         {                                                          \
274           return reinterpret_cast<type>(::rpl_func);               \
275         }                                                          \
276       } func = {};                                                 \
277     }                                                              \
278     _GL_EXTERN_C int _gl_cxxalias_dummy
279 #else
280 # define _GL_CXXALIAS_RPL_CAST_1(func,rpl_func,rettype,parameters) \
281     _GL_EXTERN_C int _gl_cxxalias_dummy
282 #endif
283 
284 /* _GL_CXXALIAS_SYS (func, rettype, parameters);
285    declares a C++ alias called GNULIB_NAMESPACE::func
286    that redirects to the system provided function func, if GNULIB_NAMESPACE
287    is defined.
288    Example:
289      _GL_CXXALIAS_SYS (open, int, (const char *filename, int flags, ...));
290 
291    Wrapping func in an object with an inline conversion operator
292    avoids a reference to func unless GNULIB_NAMESPACE::func is
293    actually used in the program.  */
294 #if defined __cplusplus && defined GNULIB_NAMESPACE
295 # define _GL_CXXALIAS_SYS(func,rettype,parameters)            \
296     namespace GNULIB_NAMESPACE                                \
297     {                                                         \
298       static const struct _gl_ ## func ## _wrapper            \
299       {                                                       \
300         typedef rettype (*type) parameters;                   \
301                                                               \
302         inline operator type () const                         \
303         {                                                     \
304           return ::func;                                      \
305         }                                                     \
306       } func = {};                                            \
307     }                                                         \
308     _GL_EXTERN_C int _gl_cxxalias_dummy
309 #else
310 # define _GL_CXXALIAS_SYS(func,rettype,parameters) \
311     _GL_EXTERN_C int _gl_cxxalias_dummy
312 #endif
313 
314 /* _GL_CXXALIAS_SYS_CAST (func, rettype, parameters);
315    is like  _GL_CXXALIAS_SYS (func, rettype, parameters);
316    except that the C function func may have a slightly different declaration.
317    A cast is used to silence the "invalid conversion" error that would
318    otherwise occur.  */
319 #if defined __cplusplus && defined GNULIB_NAMESPACE
320 # define _GL_CXXALIAS_SYS_CAST(func,rettype,parameters) \
321     namespace GNULIB_NAMESPACE                          \
322     {                                                   \
323       static const struct _gl_ ## func ## _wrapper      \
324       {                                                 \
325         typedef rettype (*type) parameters;             \
326                                                         \
327         inline operator type () const                   \
328         {                                               \
329           return reinterpret_cast<type>(::func);        \
330         }                                               \
331       } func = {};                                      \
332     }                                                   \
333     _GL_EXTERN_C int _gl_cxxalias_dummy
334 #else
335 # define _GL_CXXALIAS_SYS_CAST(func,rettype,parameters) \
336     _GL_EXTERN_C int _gl_cxxalias_dummy
337 #endif
338 
339 /* _GL_CXXALIAS_SYS_CAST2 (func, rettype, parameters, rettype2, parameters2);
340    is like  _GL_CXXALIAS_SYS (func, rettype, parameters);
341    except that the C function is picked among a set of overloaded functions,
342    namely the one with rettype2 and parameters2.  Two consecutive casts
343    are used to silence the "cannot find a match" and "invalid conversion"
344    errors that would otherwise occur.  */
345 #if defined __cplusplus && defined GNULIB_NAMESPACE
346   /* The outer cast must be a reinterpret_cast.
347      The inner cast: When the function is defined as a set of overloaded
348      functions, it works as a static_cast<>, choosing the designated variant.
349      When the function is defined as a single variant, it works as a
350      reinterpret_cast<>. The parenthesized cast syntax works both ways.  */
351 # define _GL_CXXALIAS_SYS_CAST2(func,rettype,parameters,rettype2,parameters2) \
352     namespace GNULIB_NAMESPACE                                                \
353     {                                                                         \
354       static const struct _gl_ ## func ## _wrapper                            \
355       {                                                                       \
356         typedef rettype (*type) parameters;                                   \
357                                                                               \
358         inline operator type () const                                         \
359         {                                                                     \
360           return reinterpret_cast<type>((rettype2 (*) parameters2)(::func));  \
361         }                                                                     \
362       } func = {};                                                            \
363     }                                                                         \
364     _GL_EXTERN_C int _gl_cxxalias_dummy
365 #else
366 # define _GL_CXXALIAS_SYS_CAST2(func,rettype,parameters,rettype2,parameters2) \
367     _GL_EXTERN_C int _gl_cxxalias_dummy
368 #endif
369 
370 /* _GL_CXXALIASWARN (func);
371    causes a warning to be emitted when ::func is used but not when
372    GNULIB_NAMESPACE::func is used.  func must be defined without overloaded
373    variants.  */
374 #if defined __cplusplus && defined GNULIB_NAMESPACE
375 # define _GL_CXXALIASWARN(func) \
376    _GL_CXXALIASWARN_1 (func, GNULIB_NAMESPACE)
377 # define _GL_CXXALIASWARN_1(func,namespace) \
378    _GL_CXXALIASWARN_2 (func, namespace)
379 /* To work around GCC bug <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=43881>,
380    we enable the warning only when not optimizing.  */
381 # if !__OPTIMIZE__
382 #  define _GL_CXXALIASWARN_2(func,namespace) \
383     _GL_WARN_ON_USE (func, \
384                      "The symbol ::" #func " refers to the system function. " \
385                      "Use " #namespace "::" #func " instead.")
386 # elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING
387 #  define _GL_CXXALIASWARN_2(func,namespace) \
388      extern __typeof__ (func) func
389 # else
390 #  define _GL_CXXALIASWARN_2(func,namespace) \
391      _GL_EXTERN_C int _gl_cxxalias_dummy
392 # endif
393 #else
394 # define _GL_CXXALIASWARN(func) \
395     _GL_EXTERN_C int _gl_cxxalias_dummy
396 #endif
397 
398 /* _GL_CXXALIASWARN1 (func, rettype, parameters_and_attributes);
399    causes a warning to be emitted when the given overloaded variant of ::func
400    is used but not when GNULIB_NAMESPACE::func is used.  */
401 #if defined __cplusplus && defined GNULIB_NAMESPACE
402 # define _GL_CXXALIASWARN1(func,rettype,parameters_and_attributes) \
403    _GL_CXXALIASWARN1_1 (func, rettype, parameters_and_attributes, \
404                         GNULIB_NAMESPACE)
405 # define _GL_CXXALIASWARN1_1(func,rettype,parameters_and_attributes,namespace) \
406    _GL_CXXALIASWARN1_2 (func, rettype, parameters_and_attributes, namespace)
407 /* To work around GCC bug <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=43881>,
408    we enable the warning only when not optimizing.  */
409 # if !__OPTIMIZE__
410 #  define _GL_CXXALIASWARN1_2(func,rettype,parameters_and_attributes,namespace) \
411     _GL_WARN_ON_USE_CXX (func, rettype, parameters_and_attributes, \
412                          "The symbol ::" #func " refers to the system function. " \
413                          "Use " #namespace "::" #func " instead.")
414 # else
415 #  define _GL_CXXALIASWARN1_2(func,rettype,parameters_and_attributes,namespace) \
416      _GL_EXTERN_C int _gl_cxxalias_dummy
417 # endif
418 #else
419 # define _GL_CXXALIASWARN1(func,rettype,parameters_and_attributes) \
420     _GL_EXTERN_C int _gl_cxxalias_dummy
421 #endif
422 
423 #endif /* _GL_CXXDEFS_H */
424 
425 /* The definition of _GL_ARG_NONNULL is copied here.  */
426 /* A C macro for declaring that specific arguments must not be NULL.
427    Copyright (C) 2009-2020 Free Software Foundation, Inc.
428 
429    This program is free software: you can redistribute it and/or modify it
430    under the terms of the GNU General Public License as published
431    by the Free Software Foundation; either version 3 of the License, or
432    (at your option) any later version.
433 
434    This program is distributed in the hope that it will be useful,
435    but WITHOUT ANY WARRANTY; without even the implied warranty of
436    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
437    General Public License for more details.
438 
439    You should have received a copy of the GNU General Public License
440    along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
441 
442 /* _GL_ARG_NONNULL((n,...,m)) tells the compiler and static analyzer tools
443    that the values passed as arguments n, ..., m must be non-NULL pointers.
444    n = 1 stands for the first argument, n = 2 for the second argument etc.  */
445 #ifndef _GL_ARG_NONNULL
446 # if (__GNUC__ == 3 && __GNUC_MINOR__ >= 3) || __GNUC__ > 3
447 #  define _GL_ARG_NONNULL(params) __attribute__ ((__nonnull__ params))
448 # else
449 #  define _GL_ARG_NONNULL(params)
450 # endif
451 #endif
452 
453 /* The definition of _GL_WARN_ON_USE is copied here.  */
454 /* A C macro for emitting warnings if a function is used.
455    Copyright (C) 2010-2020 Free Software Foundation, Inc.
456 
457    This program is free software: you can redistribute it and/or modify it
458    under the terms of the GNU General Public License as published
459    by the Free Software Foundation; either version 3 of the License, or
460    (at your option) any later version.
461 
462    This program is distributed in the hope that it will be useful,
463    but WITHOUT ANY WARRANTY; without even the implied warranty of
464    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
465    General Public License for more details.
466 
467    You should have received a copy of the GNU General Public License
468    along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
469 
470 /* _GL_WARN_ON_USE (function, "literal string") issues a declaration
471    for FUNCTION which will then trigger a compiler warning containing
472    the text of "literal string" anywhere that function is called, if
473    supported by the compiler.  If the compiler does not support this
474    feature, the macro expands to an unused extern declaration.
475 
476    _GL_WARN_ON_USE_ATTRIBUTE ("literal string") expands to the
477    attribute used in _GL_WARN_ON_USE.  If the compiler does not support
478    this feature, it expands to empty.
479 
480    These macros are useful for marking a function as a potential
481    portability trap, with the intent that "literal string" include
482    instructions on the replacement function that should be used
483    instead.
484    _GL_WARN_ON_USE is for functions with 'extern' linkage.
485    _GL_WARN_ON_USE_ATTRIBUTE is for functions with 'static' or 'inline'
486    linkage.
487 
488    However, one of the reasons that a function is a portability trap is
489    if it has the wrong signature.  Declaring FUNCTION with a different
490    signature in C is a compilation error, so this macro must use the
491    same type as any existing declaration so that programs that avoid
492    the problematic FUNCTION do not fail to compile merely because they
493    included a header that poisoned the function.  But this implies that
494    _GL_WARN_ON_USE is only safe to use if FUNCTION is known to already
495    have a declaration.  Use of this macro implies that there must not
496    be any other macro hiding the declaration of FUNCTION; but
497    undefining FUNCTION first is part of the poisoning process anyway
498    (although for symbols that are provided only via a macro, the result
499    is a compilation error rather than a warning containing
500    "literal string").  Also note that in C++, it is only safe to use if
501    FUNCTION has no overloads.
502 
503    For an example, it is possible to poison 'getline' by:
504    - adding a call to gl_WARN_ON_USE_PREPARE([[#include <stdio.h>]],
505      [getline]) in configure.ac, which potentially defines
506      HAVE_RAW_DECL_GETLINE
507    - adding this code to a header that wraps the system <stdio.h>:
508      #undef getline
509      #if HAVE_RAW_DECL_GETLINE
510      _GL_WARN_ON_USE (getline, "getline is required by POSIX 2008, but"
511        "not universally present; use the gnulib module getline");
512      #endif
513 
514    It is not possible to directly poison global variables.  But it is
515    possible to write a wrapper accessor function, and poison that
516    (less common usage, like &environ, will cause a compilation error
517    rather than issue the nice warning, but the end result of informing
518    the developer about their portability problem is still achieved):
519      #if HAVE_RAW_DECL_ENVIRON
520      static char ***
521      rpl_environ (void) { return &environ; }
522      _GL_WARN_ON_USE (rpl_environ, "environ is not always properly declared");
523      # undef environ
524      # define environ (*rpl_environ ())
525      #endif
526    or better (avoiding contradictory use of 'static' and 'extern'):
527      #if HAVE_RAW_DECL_ENVIRON
528      static char ***
529      _GL_WARN_ON_USE_ATTRIBUTE ("environ is not always properly declared")
530      rpl_environ (void) { return &environ; }
531      # undef environ
532      # define environ (*rpl_environ ())
533      #endif
534    */
535 #ifndef _GL_WARN_ON_USE
536 
537 # if 4 < __GNUC__ || (__GNUC__ == 4 && 3 <= __GNUC_MINOR__)
538 /* A compiler attribute is available in gcc versions 4.3.0 and later.  */
539 #  define _GL_WARN_ON_USE(function, message) \
540 extern __typeof__ (function) function __attribute__ ((__warning__ (message)))
541 #  define _GL_WARN_ON_USE_ATTRIBUTE(message) \
542   __attribute__ ((__warning__ (message)))
543 # elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING
544 /* Verify the existence of the function.  */
545 #  define _GL_WARN_ON_USE(function, message) \
546 extern __typeof__ (function) function
547 #  define _GL_WARN_ON_USE_ATTRIBUTE(message)
548 # else /* Unsupported.  */
549 #  define _GL_WARN_ON_USE(function, message) \
550 _GL_WARN_EXTERN_C int _gl_warn_on_use
551 #  define _GL_WARN_ON_USE_ATTRIBUTE(message)
552 # endif
553 #endif
554 
555 /* _GL_WARN_ON_USE_CXX (function, rettype, parameters_and_attributes, "string")
556    is like _GL_WARN_ON_USE (function, "string"), except that in C++ mode the
557    function is declared with the given prototype, consisting of return type,
558    parameters, and attributes.
559    This variant is useful for overloaded functions in C++. _GL_WARN_ON_USE does
560    not work in this case.  */
561 #ifndef _GL_WARN_ON_USE_CXX
562 # if !defined __cplusplus
563 #  define _GL_WARN_ON_USE_CXX(function,rettype,parameters_and_attributes,msg) \
564      _GL_WARN_ON_USE (function, msg)
565 # else
566 #  if 4 < __GNUC__ || (__GNUC__ == 4 && 3 <= __GNUC_MINOR__)
567 #   define _GL_WARN_ON_USE_CXX(function,rettype,parameters_and_attributes,msg) \
568 extern rettype function parameters_and_attributes \
569      __attribute__ ((__warning__ (msg)))
570 #  elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING
571 /* Verify the existence of the function.  */
572 #   define _GL_WARN_ON_USE_CXX(function,rettype,parameters_and_attributes,msg) \
573 extern rettype function parameters_and_attributes
574 #  else /* Unsupported.  */
575 #   define _GL_WARN_ON_USE_CXX(function,rettype,parameters_and_attributes,msg) \
576 _GL_WARN_EXTERN_C int _gl_warn_on_use
577 #  endif
578 # endif
579 #endif
580 
581 /* _GL_WARN_EXTERN_C declaration;
582    performs the declaration with C linkage.  */
583 #ifndef _GL_WARN_EXTERN_C
584 # if defined __cplusplus
585 #  define _GL_WARN_EXTERN_C extern "C"
586 # else
587 #  define _GL_WARN_EXTERN_C extern
588 # endif
589 #endif
590 
591 
592 /* Define wint_t and WEOF.  (Also done in wctype.in.h.)  */
593 #if !1 && !defined wint_t
594 # define wint_t int
595 # ifndef WEOF
596 #  define WEOF -1
597 # endif
598 #else
599 /* mingw and MSVC define wint_t as 'unsigned short' in <crtdefs.h> or
600    <stddef.h>.  This is too small: ISO C 99 section 7.24.1.(2) says that
601    wint_t must be "unchanged by default argument promotions".  Override it.  */
602 # if 0
603 #  if !GNULIB_defined_wint_t
604 #   if 0
605 #    include <crtdefs.h>
606 #   else
607 #    include <stddef.h>
608 #   endif
609 typedef unsigned int rpl_wint_t;
610 #   undef wint_t
611 #   define wint_t rpl_wint_t
612 #   define GNULIB_defined_wint_t 1
613 #  endif
614 # endif
615 # ifndef WEOF
616 #  define WEOF ((wint_t) -1)
617 # endif
618 #endif
619 
620 
621 /* Override mbstate_t if it is too small.
622    On IRIX 6.5, sizeof (mbstate_t) == 1, which is not sufficient for
623    implementing mbrtowc for encodings like UTF-8.
624    On AIX and MSVC, mbrtowc needs to be overridden, but mbstate_t exists and is
625    large enough and overriding it would cause problems in C++ mode.  */
626 #if !(((defined _WIN32 && !defined __CYGWIN__) || 1) && 1) || 1
627 # if !GNULIB_defined_mbstate_t
628 #  if !(defined _AIX || defined _MSC_VER)
629 typedef int rpl_mbstate_t;
630 #   undef mbstate_t
631 #   define mbstate_t rpl_mbstate_t
632 #  endif
633 #  define GNULIB_defined_mbstate_t 1
634 # endif
635 #endif
636 
637 
638 /* Convert a single-byte character to a wide character.  */
639 #if 1
640 # if 0
641 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
642 #   undef btowc
643 #   define btowc rpl_btowc
644 #  endif
645 _GL_FUNCDECL_RPL (btowc, wint_t, (int c) _GL_ATTRIBUTE_PURE);
646 _GL_CXXALIAS_RPL (btowc, wint_t, (int c));
647 # else
648 #  if !1
649 _GL_FUNCDECL_SYS (btowc, wint_t, (int c) _GL_ATTRIBUTE_PURE);
650 #  endif
651 /* Need to cast, because on mingw, the return type is 'unsigned short'.  */
652 _GL_CXXALIAS_SYS_CAST (btowc, wint_t, (int c));
653 # endif
654 # if __GLIBC__ >= 2
655 _GL_CXXALIASWARN (btowc);
656 # endif
657 #elif defined GNULIB_POSIXCHECK
658 # undef btowc
659 # if HAVE_RAW_DECL_BTOWC
660 _GL_WARN_ON_USE (btowc, "btowc is unportable - "
661                  "use gnulib module btowc for portability");
662 # endif
663 #endif
664 
665 
666 /* Convert a wide character to a single-byte character.  */
667 #if 0
668 # if 0
669 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
670 #   undef wctob
671 #   define wctob rpl_wctob
672 #  endif
673 _GL_FUNCDECL_RPL (wctob, int, (wint_t wc) _GL_ATTRIBUTE_PURE);
674 _GL_CXXALIAS_RPL (wctob, int, (wint_t wc));
675 # else
676 #  if !defined wctob && !1
677 /* wctob is provided by gnulib, or wctob exists but is not declared.  */
678 _GL_FUNCDECL_SYS (wctob, int, (wint_t wc) _GL_ATTRIBUTE_PURE);
679 #  endif
680 _GL_CXXALIAS_SYS (wctob, int, (wint_t wc));
681 # endif
682 # if __GLIBC__ >= 2
683 _GL_CXXALIASWARN (wctob);
684 # endif
685 #elif defined GNULIB_POSIXCHECK
686 # undef wctob
687 # if HAVE_RAW_DECL_WCTOB
688 _GL_WARN_ON_USE (wctob, "wctob is unportable - "
689                  "use gnulib module wctob for portability");
690 # endif
691 #endif
692 
693 
694 /* Test whether *PS is in the initial state.  */
695 #if 1
696 # if 1
697 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
698 #   undef mbsinit
699 #   define mbsinit rpl_mbsinit
700 #  endif
701 _GL_FUNCDECL_RPL (mbsinit, int, (const mbstate_t *ps));
702 _GL_CXXALIAS_RPL (mbsinit, int, (const mbstate_t *ps));
703 # else
704 #  if !1
705 _GL_FUNCDECL_SYS (mbsinit, int, (const mbstate_t *ps));
706 #  endif
707 _GL_CXXALIAS_SYS (mbsinit, int, (const mbstate_t *ps));
708 # endif
709 # if __GLIBC__ >= 2
710 _GL_CXXALIASWARN (mbsinit);
711 # endif
712 #elif defined GNULIB_POSIXCHECK
713 # undef mbsinit
714 # if HAVE_RAW_DECL_MBSINIT
715 _GL_WARN_ON_USE (mbsinit, "mbsinit is unportable - "
716                  "use gnulib module mbsinit for portability");
717 # endif
718 #endif
719 
720 
721 /* Convert a multibyte character to a wide character.  */
722 #if 1
723 # if 1
724 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
725 #   undef mbrtowc
726 #   define mbrtowc rpl_mbrtowc
727 #  endif
728 _GL_FUNCDECL_RPL (mbrtowc, size_t,
729                   (wchar_t *restrict pwc, const char *restrict s, size_t n,
730                    mbstate_t *restrict ps));
731 _GL_CXXALIAS_RPL (mbrtowc, size_t,
732                   (wchar_t *restrict pwc, const char *restrict s, size_t n,
733                    mbstate_t *restrict ps));
734 # else
735 #  if !1
736 _GL_FUNCDECL_SYS (mbrtowc, size_t,
737                   (wchar_t *restrict pwc, const char *restrict s, size_t n,
738                    mbstate_t *restrict ps));
739 #  endif
740 _GL_CXXALIAS_SYS (mbrtowc, size_t,
741                   (wchar_t *restrict pwc, const char *restrict s, size_t n,
742                    mbstate_t *restrict ps));
743 # endif
744 # if __GLIBC__ >= 2
745 _GL_CXXALIASWARN (mbrtowc);
746 # endif
747 #elif defined GNULIB_POSIXCHECK
748 # undef mbrtowc
749 # if HAVE_RAW_DECL_MBRTOWC
750 _GL_WARN_ON_USE (mbrtowc, "mbrtowc is unportable - "
751                  "use gnulib module mbrtowc for portability");
752 # endif
753 #endif
754 
755 
756 /* Recognize a multibyte character.  */
757 #if 0
758 # if 0
759 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
760 #   undef mbrlen
761 #   define mbrlen rpl_mbrlen
762 #  endif
763 _GL_FUNCDECL_RPL (mbrlen, size_t,
764                   (const char *restrict s, size_t n, mbstate_t *restrict ps));
765 _GL_CXXALIAS_RPL (mbrlen, size_t,
766                   (const char *restrict s, size_t n, mbstate_t *restrict ps));
767 # else
768 #  if !1
769 _GL_FUNCDECL_SYS (mbrlen, size_t,
770                   (const char *restrict s, size_t n, mbstate_t *restrict ps));
771 #  endif
772 _GL_CXXALIAS_SYS (mbrlen, size_t,
773                   (const char *restrict s, size_t n, mbstate_t *restrict ps));
774 # endif
775 # if __GLIBC__ >= 2
776 _GL_CXXALIASWARN (mbrlen);
777 # endif
778 #elif defined GNULIB_POSIXCHECK
779 # undef mbrlen
780 # if HAVE_RAW_DECL_MBRLEN
781 _GL_WARN_ON_USE (mbrlen, "mbrlen is unportable - "
782                  "use gnulib module mbrlen for portability");
783 # endif
784 #endif
785 
786 
787 /* Convert a string to a wide string.  */
788 #if 1
789 # if 1
790 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
791 #   undef mbsrtowcs
792 #   define mbsrtowcs rpl_mbsrtowcs
793 #  endif
794 _GL_FUNCDECL_RPL (mbsrtowcs, size_t,
795                   (wchar_t *restrict dest,
796                    const char **restrict srcp, size_t len,
797                    mbstate_t *restrict ps)
798                   _GL_ARG_NONNULL ((2)));
799 _GL_CXXALIAS_RPL (mbsrtowcs, size_t,
800                   (wchar_t *restrict dest,
801                    const char **restrict srcp, size_t len,
802                    mbstate_t *restrict ps));
803 # else
804 #  if !1
805 _GL_FUNCDECL_SYS (mbsrtowcs, size_t,
806                   (wchar_t *restrict dest,
807                    const char **restrict srcp, size_t len,
808                    mbstate_t *restrict ps)
809                   _GL_ARG_NONNULL ((2)));
810 #  endif
811 _GL_CXXALIAS_SYS (mbsrtowcs, size_t,
812                   (wchar_t *restrict dest,
813                    const char **restrict srcp, size_t len,
814                    mbstate_t *restrict ps));
815 # endif
816 # if __GLIBC__ >= 2
817 _GL_CXXALIASWARN (mbsrtowcs);
818 # endif
819 #elif defined GNULIB_POSIXCHECK
820 # undef mbsrtowcs
821 # if HAVE_RAW_DECL_MBSRTOWCS
822 _GL_WARN_ON_USE (mbsrtowcs, "mbsrtowcs is unportable - "
823                  "use gnulib module mbsrtowcs for portability");
824 # endif
825 #endif
826 
827 
828 /* Convert a string to a wide string.  */
829 #if 0
830 # if 0
831 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
832 #   undef mbsnrtowcs
833 #   define mbsnrtowcs rpl_mbsnrtowcs
834 #  endif
835 _GL_FUNCDECL_RPL (mbsnrtowcs, size_t,
836                   (wchar_t *restrict dest,
837                    const char **restrict srcp, size_t srclen, size_t len,
838                    mbstate_t *restrict ps)
839                   _GL_ARG_NONNULL ((2)));
840 _GL_CXXALIAS_RPL (mbsnrtowcs, size_t,
841                   (wchar_t *restrict dest,
842                    const char **restrict srcp, size_t srclen, size_t len,
843                    mbstate_t *restrict ps));
844 # else
845 #  if !1
846 _GL_FUNCDECL_SYS (mbsnrtowcs, size_t,
847                   (wchar_t *restrict dest,
848                    const char **restrict srcp, size_t srclen, size_t len,
849                    mbstate_t *restrict ps)
850                   _GL_ARG_NONNULL ((2)));
851 #  endif
852 _GL_CXXALIAS_SYS (mbsnrtowcs, size_t,
853                   (wchar_t *restrict dest,
854                    const char **restrict srcp, size_t srclen, size_t len,
855                    mbstate_t *restrict ps));
856 # endif
857 _GL_CXXALIASWARN (mbsnrtowcs);
858 #elif defined GNULIB_POSIXCHECK
859 # undef mbsnrtowcs
860 # if HAVE_RAW_DECL_MBSNRTOWCS
861 _GL_WARN_ON_USE (mbsnrtowcs, "mbsnrtowcs is unportable - "
862                  "use gnulib module mbsnrtowcs for portability");
863 # endif
864 #endif
865 
866 
867 /* Convert a wide character to a multibyte character.  */
868 #if 0
869 # if 0
870 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
871 #   undef wcrtomb
872 #   define wcrtomb rpl_wcrtomb
873 #  endif
874 _GL_FUNCDECL_RPL (wcrtomb, size_t,
875                   (char *restrict s, wchar_t wc, mbstate_t *restrict ps));
876 _GL_CXXALIAS_RPL (wcrtomb, size_t,
877                   (char *restrict s, wchar_t wc, mbstate_t *restrict ps));
878 # else
879 #  if !1
880 _GL_FUNCDECL_SYS (wcrtomb, size_t,
881                   (char *restrict s, wchar_t wc, mbstate_t *restrict ps));
882 #  endif
883 _GL_CXXALIAS_SYS (wcrtomb, size_t,
884                   (char *restrict s, wchar_t wc, mbstate_t *restrict ps));
885 # endif
886 # if __GLIBC__ >= 2
887 _GL_CXXALIASWARN (wcrtomb);
888 # endif
889 #elif defined GNULIB_POSIXCHECK
890 # undef wcrtomb
891 # if HAVE_RAW_DECL_WCRTOMB
892 _GL_WARN_ON_USE (wcrtomb, "wcrtomb is unportable - "
893                  "use gnulib module wcrtomb for portability");
894 # endif
895 #endif
896 
897 
898 /* Convert a wide string to a string.  */
899 #if 0
900 # if 0
901 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
902 #   undef wcsrtombs
903 #   define wcsrtombs rpl_wcsrtombs
904 #  endif
905 _GL_FUNCDECL_RPL (wcsrtombs, size_t,
906                   (char *restrict dest, const wchar_t **restrict srcp,
907                    size_t len,
908                    mbstate_t *restrict ps)
909                   _GL_ARG_NONNULL ((2)));
910 _GL_CXXALIAS_RPL (wcsrtombs, size_t,
911                   (char *restrict dest, const wchar_t **restrict srcp,
912                    size_t len,
913                    mbstate_t *restrict ps));
914 # else
915 #  if !1
916 _GL_FUNCDECL_SYS (wcsrtombs, size_t,
917                   (char *restrict dest, const wchar_t **restrict srcp,
918                    size_t len,
919                    mbstate_t *restrict ps)
920                   _GL_ARG_NONNULL ((2)));
921 #  endif
922 _GL_CXXALIAS_SYS (wcsrtombs, size_t,
923                   (char *restrict dest, const wchar_t **restrict srcp,
924                    size_t len,
925                    mbstate_t *restrict ps));
926 # endif
927 # if __GLIBC__ >= 2
928 _GL_CXXALIASWARN (wcsrtombs);
929 # endif
930 #elif defined GNULIB_POSIXCHECK
931 # undef wcsrtombs
932 # if HAVE_RAW_DECL_WCSRTOMBS
933 _GL_WARN_ON_USE (wcsrtombs, "wcsrtombs is unportable - "
934                  "use gnulib module wcsrtombs for portability");
935 # endif
936 #endif
937 
938 
939 /* Convert a wide string to a string.  */
940 #if 0
941 # if 0
942 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
943 #   undef wcsnrtombs
944 #   define wcsnrtombs rpl_wcsnrtombs
945 #  endif
946 _GL_FUNCDECL_RPL (wcsnrtombs, size_t,
947                   (char *restrict dest,
948                    const wchar_t **restrict srcp, size_t srclen,
949                    size_t len,
950                    mbstate_t *restrict ps)
951                   _GL_ARG_NONNULL ((2)));
952 _GL_CXXALIAS_RPL (wcsnrtombs, size_t,
953                   (char *restrict dest,
954                    const wchar_t **restrict srcp, size_t srclen,
955                    size_t len,
956                    mbstate_t *restrict ps));
957 # else
958 #  if !1 || (defined __cplusplus && defined __sun)
959 _GL_FUNCDECL_SYS (wcsnrtombs, size_t,
960                   (char *restrict dest,
961                    const wchar_t **restrict srcp, size_t srclen,
962                    size_t len,
963                    mbstate_t *restrict ps)
964                   _GL_ARG_NONNULL ((2)));
965 #  endif
966 _GL_CXXALIAS_SYS (wcsnrtombs, size_t,
967                   (char *restrict dest,
968                    const wchar_t **restrict srcp, size_t srclen,
969                    size_t len,
970                    mbstate_t *restrict ps));
971 # endif
972 # if __GLIBC__ >= 2
973 _GL_CXXALIASWARN (wcsnrtombs);
974 # endif
975 #elif defined GNULIB_POSIXCHECK
976 # undef wcsnrtombs
977 # if HAVE_RAW_DECL_WCSNRTOMBS
978 _GL_WARN_ON_USE (wcsnrtombs, "wcsnrtombs is unportable - "
979                  "use gnulib module wcsnrtombs for portability");
980 # endif
981 #endif
982 
983 
984 /* Return the number of screen columns needed for WC.  */
985 #if 0
986 # if 0
987 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
988 #   undef wcwidth
989 #   define wcwidth rpl_wcwidth
990 #  endif
991 _GL_FUNCDECL_RPL (wcwidth, int, (wchar_t) _GL_ATTRIBUTE_PURE);
992 _GL_CXXALIAS_RPL (wcwidth, int, (wchar_t));
993 # else
994 #  if !1
995 /* wcwidth exists but is not declared.  */
996 _GL_FUNCDECL_SYS (wcwidth, int, (wchar_t) _GL_ATTRIBUTE_PURE);
997 #  endif
998 _GL_CXXALIAS_SYS (wcwidth, int, (wchar_t));
999 # endif
1000 # if __GLIBC__ >= 2
1001 _GL_CXXALIASWARN (wcwidth);
1002 # endif
1003 #elif defined GNULIB_POSIXCHECK
1004 # undef wcwidth
1005 # if HAVE_RAW_DECL_WCWIDTH
1006 _GL_WARN_ON_USE (wcwidth, "wcwidth is unportable - "
1007                  "use gnulib module wcwidth for portability");
1008 # endif
1009 #endif
1010 
1011 
1012 /* Search N wide characters of S for C.  */
1013 #if 1
1014 # if !1
1015 _GL_FUNCDECL_SYS (wmemchr, wchar_t *, (const wchar_t *s, wchar_t c, size_t n)
1016                                       _GL_ATTRIBUTE_PURE);
1017 # endif
1018   /* On some systems, this function is defined as an overloaded function:
1019        extern "C++" {
1020          const wchar_t * std::wmemchr (const wchar_t *, wchar_t, size_t);
1021          wchar_t * std::wmemchr (wchar_t *, wchar_t, size_t);
1022        }  */
1023 _GL_CXXALIAS_SYS_CAST2 (wmemchr,
1024                         wchar_t *, (const wchar_t *, wchar_t, size_t),
1025                         const wchar_t *, (const wchar_t *, wchar_t, size_t));
1026 # if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
1027      && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
1028 _GL_CXXALIASWARN1 (wmemchr, wchar_t *, (wchar_t *s, wchar_t c, size_t n));
1029 _GL_CXXALIASWARN1 (wmemchr, const wchar_t *,
1030                    (const wchar_t *s, wchar_t c, size_t n));
1031 # elif __GLIBC__ >= 2
1032 _GL_CXXALIASWARN (wmemchr);
1033 # endif
1034 #elif defined GNULIB_POSIXCHECK
1035 # undef wmemchr
1036 # if HAVE_RAW_DECL_WMEMCHR
1037 _GL_WARN_ON_USE (wmemchr, "wmemchr is unportable - "
1038                  "use gnulib module wmemchr for portability");
1039 # endif
1040 #endif
1041 
1042 
1043 /* Compare N wide characters of S1 and S2.  */
1044 #if 0
1045 # if !1
1046 _GL_FUNCDECL_SYS (wmemcmp, int,
1047                   (const wchar_t *s1, const wchar_t *s2, size_t n)
1048                   _GL_ATTRIBUTE_PURE);
1049 # endif
1050 _GL_CXXALIAS_SYS (wmemcmp, int,
1051                   (const wchar_t *s1, const wchar_t *s2, size_t n));
1052 # if __GLIBC__ >= 2
1053 _GL_CXXALIASWARN (wmemcmp);
1054 # endif
1055 #elif defined GNULIB_POSIXCHECK
1056 # undef wmemcmp
1057 # if HAVE_RAW_DECL_WMEMCMP
1058 _GL_WARN_ON_USE (wmemcmp, "wmemcmp is unportable - "
1059                  "use gnulib module wmemcmp for portability");
1060 # endif
1061 #endif
1062 
1063 
1064 /* Copy N wide characters of SRC to DEST.  */
1065 #if 0
1066 # if !1
1067 _GL_FUNCDECL_SYS (wmemcpy, wchar_t *,
1068                   (wchar_t *restrict dest,
1069                    const wchar_t *restrict src, size_t n));
1070 # endif
1071 _GL_CXXALIAS_SYS (wmemcpy, wchar_t *,
1072                   (wchar_t *restrict dest,
1073                    const wchar_t *restrict src, size_t n));
1074 # if __GLIBC__ >= 2
1075 _GL_CXXALIASWARN (wmemcpy);
1076 # endif
1077 #elif defined GNULIB_POSIXCHECK
1078 # undef wmemcpy
1079 # if HAVE_RAW_DECL_WMEMCPY
1080 _GL_WARN_ON_USE (wmemcpy, "wmemcpy is unportable - "
1081                  "use gnulib module wmemcpy for portability");
1082 # endif
1083 #endif
1084 
1085 
1086 /* Copy N wide characters of SRC to DEST, guaranteeing correct behavior for
1087    overlapping memory areas.  */
1088 #if 0
1089 # if !1
1090 _GL_FUNCDECL_SYS (wmemmove, wchar_t *,
1091                   (wchar_t *dest, const wchar_t *src, size_t n));
1092 # endif
1093 _GL_CXXALIAS_SYS (wmemmove, wchar_t *,
1094                   (wchar_t *dest, const wchar_t *src, size_t n));
1095 # if __GLIBC__ >= 2
1096 _GL_CXXALIASWARN (wmemmove);
1097 # endif
1098 #elif defined GNULIB_POSIXCHECK
1099 # undef wmemmove
1100 # if HAVE_RAW_DECL_WMEMMOVE
1101 _GL_WARN_ON_USE (wmemmove, "wmemmove is unportable - "
1102                  "use gnulib module wmemmove for portability");
1103 # endif
1104 #endif
1105 
1106 
1107 /* Copy N wide characters of SRC to DEST.
1108    Return pointer to wide characters after the last written wide character.  */
1109 #if 1
1110 # if !0
1111 _GL_FUNCDECL_SYS (wmempcpy, wchar_t *,
1112                   (wchar_t *restrict dest,
1113                    const wchar_t *restrict src, size_t n));
1114 # endif
1115 _GL_CXXALIAS_SYS (wmempcpy, wchar_t *,
1116                   (wchar_t *restrict dest,
1117                    const wchar_t *restrict src, size_t n));
1118 # if __GLIBC__ >= 2
1119 _GL_CXXALIASWARN (wmempcpy);
1120 # endif
1121 #elif defined GNULIB_POSIXCHECK
1122 # undef wmempcpy
1123 # if HAVE_RAW_DECL_WMEMPCPY
1124 _GL_WARN_ON_USE (wmempcpy, "wmempcpy is unportable - "
1125                  "use gnulib module wmempcpy for portability");
1126 # endif
1127 #endif
1128 
1129 
1130 /* Set N wide characters of S to C.  */
1131 #if 0
1132 # if !1
1133 _GL_FUNCDECL_SYS (wmemset, wchar_t *, (wchar_t *s, wchar_t c, size_t n));
1134 # endif
1135 _GL_CXXALIAS_SYS (wmemset, wchar_t *, (wchar_t *s, wchar_t c, size_t n));
1136 # if __GLIBC__ >= 2
1137 _GL_CXXALIASWARN (wmemset);
1138 # endif
1139 #elif defined GNULIB_POSIXCHECK
1140 # undef wmemset
1141 # if HAVE_RAW_DECL_WMEMSET
1142 _GL_WARN_ON_USE (wmemset, "wmemset is unportable - "
1143                  "use gnulib module wmemset for portability");
1144 # endif
1145 #endif
1146 
1147 
1148 /* Return the number of wide characters in S.  */
1149 #if 0
1150 # if !1
1151 _GL_FUNCDECL_SYS (wcslen, size_t, (const wchar_t *s) _GL_ATTRIBUTE_PURE);
1152 # endif
1153 _GL_CXXALIAS_SYS (wcslen, size_t, (const wchar_t *s));
1154 # if __GLIBC__ >= 2
1155 _GL_CXXALIASWARN (wcslen);
1156 # endif
1157 #elif defined GNULIB_POSIXCHECK
1158 # undef wcslen
1159 # if HAVE_RAW_DECL_WCSLEN
1160 _GL_WARN_ON_USE (wcslen, "wcslen is unportable - "
1161                  "use gnulib module wcslen for portability");
1162 # endif
1163 #endif
1164 
1165 
1166 /* Return the number of wide characters in S, but at most MAXLEN.  */
1167 #if 0
1168 # if !1
1169 _GL_FUNCDECL_SYS (wcsnlen, size_t, (const wchar_t *s, size_t maxlen)
1170                                    _GL_ATTRIBUTE_PURE);
1171 # endif
1172 _GL_CXXALIAS_SYS (wcsnlen, size_t, (const wchar_t *s, size_t maxlen));
1173 _GL_CXXALIASWARN (wcsnlen);
1174 #elif defined GNULIB_POSIXCHECK
1175 # undef wcsnlen
1176 # if HAVE_RAW_DECL_WCSNLEN
1177 _GL_WARN_ON_USE (wcsnlen, "wcsnlen is unportable - "
1178                  "use gnulib module wcsnlen for portability");
1179 # endif
1180 #endif
1181 
1182 
1183 /* Copy SRC to DEST.  */
1184 #if 0
1185 # if !1
1186 _GL_FUNCDECL_SYS (wcscpy, wchar_t *,
1187                   (wchar_t *restrict dest, const wchar_t *restrict src));
1188 # endif
1189 _GL_CXXALIAS_SYS (wcscpy, wchar_t *,
1190                   (wchar_t *restrict dest, const wchar_t *restrict src));
1191 # if __GLIBC__ >= 2
1192 _GL_CXXALIASWARN (wcscpy);
1193 # endif
1194 #elif defined GNULIB_POSIXCHECK
1195 # undef wcscpy
1196 # if HAVE_RAW_DECL_WCSCPY
1197 _GL_WARN_ON_USE (wcscpy, "wcscpy is unportable - "
1198                  "use gnulib module wcscpy for portability");
1199 # endif
1200 #endif
1201 
1202 
1203 /* Copy SRC to DEST, returning the address of the terminating L'\0' in DEST.  */
1204 #if 0
1205 # if !1
1206 _GL_FUNCDECL_SYS (wcpcpy, wchar_t *,
1207                   (wchar_t *restrict dest, const wchar_t *restrict src));
1208 # endif
1209 _GL_CXXALIAS_SYS (wcpcpy, wchar_t *,
1210                   (wchar_t *restrict dest, const wchar_t *restrict src));
1211 _GL_CXXALIASWARN (wcpcpy);
1212 #elif defined GNULIB_POSIXCHECK
1213 # undef wcpcpy
1214 # if HAVE_RAW_DECL_WCPCPY
1215 _GL_WARN_ON_USE (wcpcpy, "wcpcpy is unportable - "
1216                  "use gnulib module wcpcpy for portability");
1217 # endif
1218 #endif
1219 
1220 
1221 /* Copy no more than N wide characters of SRC to DEST.  */
1222 #if 0
1223 # if !1
1224 _GL_FUNCDECL_SYS (wcsncpy, wchar_t *,
1225                   (wchar_t *restrict dest,
1226                    const wchar_t *restrict src, size_t n));
1227 # endif
1228 _GL_CXXALIAS_SYS (wcsncpy, wchar_t *,
1229                   (wchar_t *restrict dest,
1230                    const wchar_t *restrict src, size_t n));
1231 # if __GLIBC__ >= 2
1232 _GL_CXXALIASWARN (wcsncpy);
1233 # endif
1234 #elif defined GNULIB_POSIXCHECK
1235 # undef wcsncpy
1236 # if HAVE_RAW_DECL_WCSNCPY
1237 _GL_WARN_ON_USE (wcsncpy, "wcsncpy is unportable - "
1238                  "use gnulib module wcsncpy for portability");
1239 # endif
1240 #endif
1241 
1242 
1243 /* Copy no more than N characters of SRC to DEST, returning the address of
1244    the last character written into DEST.  */
1245 #if 0
1246 # if !1
1247 _GL_FUNCDECL_SYS (wcpncpy, wchar_t *,
1248                   (wchar_t *restrict dest,
1249                    const wchar_t *restrict src, size_t n));
1250 # endif
1251 _GL_CXXALIAS_SYS (wcpncpy, wchar_t *,
1252                   (wchar_t *restrict dest,
1253                    const wchar_t *restrict src, size_t n));
1254 _GL_CXXALIASWARN (wcpncpy);
1255 #elif defined GNULIB_POSIXCHECK
1256 # undef wcpncpy
1257 # if HAVE_RAW_DECL_WCPNCPY
1258 _GL_WARN_ON_USE (wcpncpy, "wcpncpy is unportable - "
1259                  "use gnulib module wcpncpy for portability");
1260 # endif
1261 #endif
1262 
1263 
1264 /* Append SRC onto DEST.  */
1265 #if 0
1266 # if !1
1267 _GL_FUNCDECL_SYS (wcscat, wchar_t *,
1268                   (wchar_t *restrict dest, const wchar_t *restrict src));
1269 # endif
1270 _GL_CXXALIAS_SYS (wcscat, wchar_t *,
1271                   (wchar_t *restrict dest, const wchar_t *restrict src));
1272 # if __GLIBC__ >= 2
1273 _GL_CXXALIASWARN (wcscat);
1274 # endif
1275 #elif defined GNULIB_POSIXCHECK
1276 # undef wcscat
1277 # if HAVE_RAW_DECL_WCSCAT
1278 _GL_WARN_ON_USE (wcscat, "wcscat is unportable - "
1279                  "use gnulib module wcscat for portability");
1280 # endif
1281 #endif
1282 
1283 
1284 /* Append no more than N wide characters of SRC onto DEST.  */
1285 #if 0
1286 # if !1
1287 _GL_FUNCDECL_SYS (wcsncat, wchar_t *,
1288                   (wchar_t *restrict dest, const wchar_t *restrict src,
1289                    size_t n));
1290 # endif
1291 _GL_CXXALIAS_SYS (wcsncat, wchar_t *,
1292                   (wchar_t *restrict dest, const wchar_t *restrict src,
1293                    size_t n));
1294 # if __GLIBC__ >= 2
1295 _GL_CXXALIASWARN (wcsncat);
1296 # endif
1297 #elif defined GNULIB_POSIXCHECK
1298 # undef wcsncat
1299 # if HAVE_RAW_DECL_WCSNCAT
1300 _GL_WARN_ON_USE (wcsncat, "wcsncat is unportable - "
1301                  "use gnulib module wcsncat for portability");
1302 # endif
1303 #endif
1304 
1305 
1306 /* Compare S1 and S2.  */
1307 #if 0
1308 # if !1
1309 _GL_FUNCDECL_SYS (wcscmp, int, (const wchar_t *s1, const wchar_t *s2)
1310                                _GL_ATTRIBUTE_PURE);
1311 # endif
1312 _GL_CXXALIAS_SYS (wcscmp, int, (const wchar_t *s1, const wchar_t *s2));
1313 # if __GLIBC__ >= 2
1314 _GL_CXXALIASWARN (wcscmp);
1315 # endif
1316 #elif defined GNULIB_POSIXCHECK
1317 # undef wcscmp
1318 # if HAVE_RAW_DECL_WCSCMP
1319 _GL_WARN_ON_USE (wcscmp, "wcscmp is unportable - "
1320                  "use gnulib module wcscmp for portability");
1321 # endif
1322 #endif
1323 
1324 
1325 /* Compare no more than N wide characters of S1 and S2.  */
1326 #if 0
1327 # if !1
1328 _GL_FUNCDECL_SYS (wcsncmp, int,
1329                   (const wchar_t *s1, const wchar_t *s2, size_t n)
1330                   _GL_ATTRIBUTE_PURE);
1331 # endif
1332 _GL_CXXALIAS_SYS (wcsncmp, int,
1333                   (const wchar_t *s1, const wchar_t *s2, size_t n));
1334 # if __GLIBC__ >= 2
1335 _GL_CXXALIASWARN (wcsncmp);
1336 # endif
1337 #elif defined GNULIB_POSIXCHECK
1338 # undef wcsncmp
1339 # if HAVE_RAW_DECL_WCSNCMP
1340 _GL_WARN_ON_USE (wcsncmp, "wcsncmp is unportable - "
1341                  "use gnulib module wcsncmp for portability");
1342 # endif
1343 #endif
1344 
1345 
1346 /* Compare S1 and S2, ignoring case.  */
1347 #if 0
1348 # if !1
1349 _GL_FUNCDECL_SYS (wcscasecmp, int, (const wchar_t *s1, const wchar_t *s2)
1350                                    _GL_ATTRIBUTE_PURE);
1351 # endif
1352 _GL_CXXALIAS_SYS (wcscasecmp, int, (const wchar_t *s1, const wchar_t *s2));
1353 _GL_CXXALIASWARN (wcscasecmp);
1354 #elif defined GNULIB_POSIXCHECK
1355 # undef wcscasecmp
1356 # if HAVE_RAW_DECL_WCSCASECMP
1357 _GL_WARN_ON_USE (wcscasecmp, "wcscasecmp is unportable - "
1358                  "use gnulib module wcscasecmp for portability");
1359 # endif
1360 #endif
1361 
1362 
1363 /* Compare no more than N chars of S1 and S2, ignoring case.  */
1364 #if 0
1365 # if !1
1366 _GL_FUNCDECL_SYS (wcsncasecmp, int,
1367                   (const wchar_t *s1, const wchar_t *s2, size_t n)
1368                   _GL_ATTRIBUTE_PURE);
1369 # endif
1370 _GL_CXXALIAS_SYS (wcsncasecmp, int,
1371                   (const wchar_t *s1, const wchar_t *s2, size_t n));
1372 _GL_CXXALIASWARN (wcsncasecmp);
1373 #elif defined GNULIB_POSIXCHECK
1374 # undef wcsncasecmp
1375 # if HAVE_RAW_DECL_WCSNCASECMP
1376 _GL_WARN_ON_USE (wcsncasecmp, "wcsncasecmp is unportable - "
1377                  "use gnulib module wcsncasecmp for portability");
1378 # endif
1379 #endif
1380 
1381 
1382 /* Compare S1 and S2, both interpreted as appropriate to the LC_COLLATE
1383    category of the current locale.  */
1384 #if 0
1385 # if !1
1386 _GL_FUNCDECL_SYS (wcscoll, int, (const wchar_t *s1, const wchar_t *s2));
1387 # endif
1388 _GL_CXXALIAS_SYS (wcscoll, int, (const wchar_t *s1, const wchar_t *s2));
1389 # if __GLIBC__ >= 2
1390 _GL_CXXALIASWARN (wcscoll);
1391 # endif
1392 #elif defined GNULIB_POSIXCHECK
1393 # undef wcscoll
1394 # if HAVE_RAW_DECL_WCSCOLL
1395 _GL_WARN_ON_USE (wcscoll, "wcscoll is unportable - "
1396                  "use gnulib module wcscoll for portability");
1397 # endif
1398 #endif
1399 
1400 
1401 /* Transform S2 into array pointed to by S1 such that if wcscmp is applied
1402    to two transformed strings the result is the as applying 'wcscoll' to the
1403    original strings.  */
1404 #if 0
1405 # if !1
1406 _GL_FUNCDECL_SYS (wcsxfrm, size_t,
1407                   (wchar_t *restrict s1, const wchar_t *restrict s2, size_t n));
1408 # endif
1409 _GL_CXXALIAS_SYS (wcsxfrm, size_t,
1410                   (wchar_t *restrict s1, const wchar_t *restrict s2, size_t n));
1411 # if __GLIBC__ >= 2
1412 _GL_CXXALIASWARN (wcsxfrm);
1413 # endif
1414 #elif defined GNULIB_POSIXCHECK
1415 # undef wcsxfrm
1416 # if HAVE_RAW_DECL_WCSXFRM
1417 _GL_WARN_ON_USE (wcsxfrm, "wcsxfrm is unportable - "
1418                  "use gnulib module wcsxfrm for portability");
1419 # endif
1420 #endif
1421 
1422 
1423 /* Duplicate S, returning an identical malloc'd string.  */
1424 #if 0
1425 # if !1
1426 _GL_FUNCDECL_SYS (wcsdup, wchar_t *, (const wchar_t *s));
1427 # endif
1428 _GL_CXXALIAS_SYS (wcsdup, wchar_t *, (const wchar_t *s));
1429 _GL_CXXALIASWARN (wcsdup);
1430 #elif defined GNULIB_POSIXCHECK
1431 # undef wcsdup
1432 # if HAVE_RAW_DECL_WCSDUP
1433 _GL_WARN_ON_USE (wcsdup, "wcsdup is unportable - "
1434                  "use gnulib module wcsdup for portability");
1435 # endif
1436 #endif
1437 
1438 
1439 /* Find the first occurrence of WC in WCS.  */
1440 #if 0
1441 # if !1
1442 _GL_FUNCDECL_SYS (wcschr, wchar_t *, (const wchar_t *wcs, wchar_t wc)
1443                                      _GL_ATTRIBUTE_PURE);
1444 # endif
1445   /* On some systems, this function is defined as an overloaded function:
1446        extern "C++" {
1447          const wchar_t * std::wcschr (const wchar_t *, wchar_t);
1448          wchar_t * std::wcschr (wchar_t *, wchar_t);
1449        }  */
1450 _GL_CXXALIAS_SYS_CAST2 (wcschr,
1451                         wchar_t *, (const wchar_t *, wchar_t),
1452                         const wchar_t *, (const wchar_t *, wchar_t));
1453 # if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
1454      && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
1455 _GL_CXXALIASWARN1 (wcschr, wchar_t *, (wchar_t *wcs, wchar_t wc));
1456 _GL_CXXALIASWARN1 (wcschr, const wchar_t *, (const wchar_t *wcs, wchar_t wc));
1457 # elif __GLIBC__ >= 2
1458 _GL_CXXALIASWARN (wcschr);
1459 # endif
1460 #elif defined GNULIB_POSIXCHECK
1461 # undef wcschr
1462 # if HAVE_RAW_DECL_WCSCHR
1463 _GL_WARN_ON_USE (wcschr, "wcschr is unportable - "
1464                  "use gnulib module wcschr for portability");
1465 # endif
1466 #endif
1467 
1468 
1469 /* Find the last occurrence of WC in WCS.  */
1470 #if 0
1471 # if !1
1472 _GL_FUNCDECL_SYS (wcsrchr, wchar_t *, (const wchar_t *wcs, wchar_t wc)
1473                                       _GL_ATTRIBUTE_PURE);
1474 # endif
1475   /* On some systems, this function is defined as an overloaded function:
1476        extern "C++" {
1477          const wchar_t * std::wcsrchr (const wchar_t *, wchar_t);
1478          wchar_t * std::wcsrchr (wchar_t *, wchar_t);
1479        }  */
1480 _GL_CXXALIAS_SYS_CAST2 (wcsrchr,
1481                         wchar_t *, (const wchar_t *, wchar_t),
1482                         const wchar_t *, (const wchar_t *, wchar_t));
1483 # if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
1484      && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
1485 _GL_CXXALIASWARN1 (wcsrchr, wchar_t *, (wchar_t *wcs, wchar_t wc));
1486 _GL_CXXALIASWARN1 (wcsrchr, const wchar_t *, (const wchar_t *wcs, wchar_t wc));
1487 # elif __GLIBC__ >= 2
1488 _GL_CXXALIASWARN (wcsrchr);
1489 # endif
1490 #elif defined GNULIB_POSIXCHECK
1491 # undef wcsrchr
1492 # if HAVE_RAW_DECL_WCSRCHR
1493 _GL_WARN_ON_USE (wcsrchr, "wcsrchr is unportable - "
1494                  "use gnulib module wcsrchr for portability");
1495 # endif
1496 #endif
1497 
1498 
1499 /* Return the length of the initial segmet of WCS which consists entirely
1500    of wide characters not in REJECT.  */
1501 #if 0
1502 # if !1
1503 _GL_FUNCDECL_SYS (wcscspn, size_t, (const wchar_t *wcs, const wchar_t *reject)
1504                                    _GL_ATTRIBUTE_PURE);
1505 # endif
1506 _GL_CXXALIAS_SYS (wcscspn, size_t, (const wchar_t *wcs, const wchar_t *reject));
1507 # if __GLIBC__ >= 2
1508 _GL_CXXALIASWARN (wcscspn);
1509 # endif
1510 #elif defined GNULIB_POSIXCHECK
1511 # undef wcscspn
1512 # if HAVE_RAW_DECL_WCSCSPN
1513 _GL_WARN_ON_USE (wcscspn, "wcscspn is unportable - "
1514                  "use gnulib module wcscspn for portability");
1515 # endif
1516 #endif
1517 
1518 
1519 /* Return the length of the initial segmet of WCS which consists entirely
1520    of wide characters in ACCEPT.  */
1521 #if 0
1522 # if !1
1523 _GL_FUNCDECL_SYS (wcsspn, size_t, (const wchar_t *wcs, const wchar_t *accept)
1524                                   _GL_ATTRIBUTE_PURE);
1525 # endif
1526 _GL_CXXALIAS_SYS (wcsspn, size_t, (const wchar_t *wcs, const wchar_t *accept));
1527 # if __GLIBC__ >= 2
1528 _GL_CXXALIASWARN (wcsspn);
1529 # endif
1530 #elif defined GNULIB_POSIXCHECK
1531 # undef wcsspn
1532 # if HAVE_RAW_DECL_WCSSPN
1533 _GL_WARN_ON_USE (wcsspn, "wcsspn is unportable - "
1534                  "use gnulib module wcsspn for portability");
1535 # endif
1536 #endif
1537 
1538 
1539 /* Find the first occurrence in WCS of any character in ACCEPT.  */
1540 #if 0
1541 # if !1
1542 _GL_FUNCDECL_SYS (wcspbrk, wchar_t *,
1543                   (const wchar_t *wcs, const wchar_t *accept)
1544                   _GL_ATTRIBUTE_PURE);
1545 # endif
1546   /* On some systems, this function is defined as an overloaded function:
1547        extern "C++" {
1548          const wchar_t * std::wcspbrk (const wchar_t *, const wchar_t *);
1549          wchar_t * std::wcspbrk (wchar_t *, const wchar_t *);
1550        }  */
1551 _GL_CXXALIAS_SYS_CAST2 (wcspbrk,
1552                         wchar_t *, (const wchar_t *, const wchar_t *),
1553                         const wchar_t *, (const wchar_t *, const wchar_t *));
1554 # if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
1555      && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
1556 _GL_CXXALIASWARN1 (wcspbrk, wchar_t *,
1557                    (wchar_t *wcs, const wchar_t *accept));
1558 _GL_CXXALIASWARN1 (wcspbrk, const wchar_t *,
1559                    (const wchar_t *wcs, const wchar_t *accept));
1560 # elif __GLIBC__ >= 2
1561 _GL_CXXALIASWARN (wcspbrk);
1562 # endif
1563 #elif defined GNULIB_POSIXCHECK
1564 # undef wcspbrk
1565 # if HAVE_RAW_DECL_WCSPBRK
1566 _GL_WARN_ON_USE (wcspbrk, "wcspbrk is unportable - "
1567                  "use gnulib module wcspbrk for portability");
1568 # endif
1569 #endif
1570 
1571 
1572 /* Find the first occurrence of NEEDLE in HAYSTACK.  */
1573 #if 0
1574 # if !1
1575 _GL_FUNCDECL_SYS (wcsstr, wchar_t *,
1576                   (const wchar_t *restrict haystack,
1577                    const wchar_t *restrict needle)
1578                   _GL_ATTRIBUTE_PURE);
1579 # endif
1580   /* On some systems, this function is defined as an overloaded function:
1581        extern "C++" {
1582          const wchar_t * std::wcsstr (const wchar_t *, const wchar_t *);
1583          wchar_t * std::wcsstr (wchar_t *, const wchar_t *);
1584        }  */
1585 _GL_CXXALIAS_SYS_CAST2 (wcsstr,
1586                         wchar_t *,
1587                         (const wchar_t *restrict, const wchar_t *restrict),
1588                         const wchar_t *,
1589                         (const wchar_t *restrict, const wchar_t *restrict));
1590 # if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 10) && !defined __UCLIBC__) \
1591      && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
1592 _GL_CXXALIASWARN1 (wcsstr, wchar_t *,
1593                    (wchar_t *restrict haystack,
1594                     const wchar_t *restrict needle));
1595 _GL_CXXALIASWARN1 (wcsstr, const wchar_t *,
1596                    (const wchar_t *restrict haystack,
1597                     const wchar_t *restrict needle));
1598 # elif __GLIBC__ >= 2
1599 _GL_CXXALIASWARN (wcsstr);
1600 # endif
1601 #elif defined GNULIB_POSIXCHECK
1602 # undef wcsstr
1603 # if HAVE_RAW_DECL_WCSSTR
1604 _GL_WARN_ON_USE (wcsstr, "wcsstr is unportable - "
1605                  "use gnulib module wcsstr for portability");
1606 # endif
1607 #endif
1608 
1609 
1610 /* Divide WCS into tokens separated by characters in DELIM.  */
1611 #if 0
1612 # if 0
1613 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1614 #   undef wcstok
1615 #   define wcstok rpl_wcstok
1616 #  endif
1617 _GL_FUNCDECL_RPL (wcstok, wchar_t *,
1618                   (wchar_t *restrict wcs, const wchar_t *restrict delim,
1619                    wchar_t **restrict ptr));
1620 _GL_CXXALIAS_RPL (wcstok, wchar_t *,
1621                   (wchar_t *restrict wcs, const wchar_t *restrict delim,
1622                    wchar_t **restrict ptr));
1623 # else
1624 #  if !1
1625 _GL_FUNCDECL_SYS (wcstok, wchar_t *,
1626                   (wchar_t *restrict wcs, const wchar_t *restrict delim,
1627                    wchar_t **restrict ptr));
1628 #  endif
1629 _GL_CXXALIAS_SYS (wcstok, wchar_t *,
1630                   (wchar_t *restrict wcs, const wchar_t *restrict delim,
1631                    wchar_t **restrict ptr));
1632 # endif
1633 # if __GLIBC__ >= 2
1634 _GL_CXXALIASWARN (wcstok);
1635 # endif
1636 #elif defined GNULIB_POSIXCHECK
1637 # undef wcstok
1638 # if HAVE_RAW_DECL_WCSTOK
1639 _GL_WARN_ON_USE (wcstok, "wcstok is unportable - "
1640                  "use gnulib module wcstok for portability");
1641 # endif
1642 #endif
1643 
1644 
1645 /* Determine number of column positions required for first N wide
1646    characters (or fewer if S ends before this) in S.  */
1647 #if 0
1648 # if 0
1649 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1650 #   undef wcswidth
1651 #   define wcswidth rpl_wcswidth
1652 #  endif
1653 _GL_FUNCDECL_RPL (wcswidth, int, (const wchar_t *s, size_t n)
1654                                  _GL_ATTRIBUTE_PURE);
1655 _GL_CXXALIAS_RPL (wcswidth, int, (const wchar_t *s, size_t n));
1656 # else
1657 #  if !1
1658 _GL_FUNCDECL_SYS (wcswidth, int, (const wchar_t *s, size_t n)
1659                                  _GL_ATTRIBUTE_PURE);
1660 #  endif
1661 _GL_CXXALIAS_SYS (wcswidth, int, (const wchar_t *s, size_t n));
1662 # endif
1663 # if __GLIBC__ >= 2
1664 _GL_CXXALIASWARN (wcswidth);
1665 # endif
1666 #elif defined GNULIB_POSIXCHECK
1667 # undef wcswidth
1668 # if HAVE_RAW_DECL_WCSWIDTH
1669 _GL_WARN_ON_USE (wcswidth, "wcswidth is unportable - "
1670                  "use gnulib module wcswidth for portability");
1671 # endif
1672 #endif
1673 
1674 
1675 /* Convert *TP to a date and time wide string.  See
1676    <https://pubs.opengroup.org/onlinepubs/9699919799/functions/wcsftime.html>.  */
1677 #if 0
1678 # if 0
1679 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1680 #   undef wcsftime
1681 #   define wcsftime rpl_wcsftime
1682 #  endif
1683 _GL_FUNCDECL_RPL (wcsftime, size_t,
1684                   (wchar_t *restrict __buf, size_t __bufsize,
1685                    const wchar_t *restrict __fmt,
1686                    const struct tm *restrict __tp)
1687                   _GL_ARG_NONNULL ((1, 3, 4)));
1688 _GL_CXXALIAS_RPL (wcsftime, size_t,
1689                   (wchar_t *restrict __buf, size_t __bufsize,
1690                    const wchar_t *restrict __fmt,
1691                    const struct tm *restrict __tp));
1692 # else
1693 #  if !1
1694 _GL_FUNCDECL_SYS (wcsftime, size_t,
1695                   (wchar_t *restrict __buf, size_t __bufsize,
1696                    const wchar_t *restrict __fmt,
1697                    const struct tm *restrict __tp)
1698                   _GL_ARG_NONNULL ((1, 3, 4)));
1699 #  endif
1700 _GL_CXXALIAS_SYS (wcsftime, size_t,
1701                   (wchar_t *restrict __buf, size_t __bufsize,
1702                    const wchar_t *restrict __fmt,
1703                    const struct tm *restrict __tp));
1704 # endif
1705 # if __GLIBC__ >= 2
1706 _GL_CXXALIASWARN (wcsftime);
1707 # endif
1708 #elif defined GNULIB_POSIXCHECK
1709 # undef wcsftime
1710 # if HAVE_RAW_DECL_WCSFTIME
1711 _GL_WARN_ON_USE (wcsftime, "wcsftime is unportable - "
1712                  "use gnulib module wcsftime for portability");
1713 # endif
1714 #endif
1715 
1716 
1717 #endif /* _GL_WCHAR_H */
1718 #endif /* _GL_WCHAR_H */
1719 #endif
1720