source: Daodan/MSYS2/mingw32/lib/gcc/i686-w64-mingw32/11.2.0/include/stdarg.h

Last change on this file was 1166, checked in by rossy, 3 years ago

Daodan: Replace MinGW build env with an up-to-date MSYS2 env

File size: 4.0 KB
RevLine 
[1166]1#include_next <stdarg.h>
2/* Copyright (C) 1989-2021 Free Software Foundation, Inc.
3
4This file is part of GCC.
5
6GCC is free software; you can redistribute it and/or modify
7it under the terms of the GNU General Public License as published by
8the Free Software Foundation; either version 3, or (at your option)
9any later version.
10
11GCC is distributed in the hope that it will be useful,
12but WITHOUT ANY WARRANTY; without even the implied warranty of
13MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14GNU General Public License for more details.
15
16Under Section 7 of GPL version 3, you are granted additional
17permissions described in the GCC Runtime Library Exception, version
183.1, as published by the Free Software Foundation.
19
20You should have received a copy of the GNU General Public License and
21a copy of the GCC Runtime Library Exception along with this program;
22see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
23<http://www.gnu.org/licenses/>. */
24
25/*
26 * ISO C Standard: 7.15 Variable arguments <stdarg.h>
27 */
28
29#ifndef _STDARG_H
30#ifndef _ANSI_STDARG_H_
31#ifndef __need___va_list
32#define _STDARG_H
33#define _ANSI_STDARG_H_
34#endif /* not __need___va_list */
35#undef __need___va_list
36
37/* Define __gnuc_va_list. */
38
39#ifndef __GNUC_VA_LIST
40#define __GNUC_VA_LIST
41typedef __builtin_va_list __gnuc_va_list;
42#endif
43
44/* Define the standard macros for the user,
45 if this invocation was from the user program. */
46#ifdef _STDARG_H
47
48#define va_start(v,l) __builtin_va_start(v,l)
49#define va_end(v) __builtin_va_end(v)
50#define va_arg(v,l) __builtin_va_arg(v,l)
51#if !defined(__STRICT_ANSI__) || __STDC_VERSION__ + 0 >= 199900L \
52 || __cplusplus + 0 >= 201103L
53#define va_copy(d,s) __builtin_va_copy(d,s)
54#endif
55#define __va_copy(d,s) __builtin_va_copy(d,s)
56
57/* Define va_list, if desired, from __gnuc_va_list. */
58/* We deliberately do not define va_list when called from
59 stdio.h, because ANSI C says that stdio.h is not supposed to define
60 va_list. stdio.h needs to have access to that data type,
61 but must not use that name. It should use the name __gnuc_va_list,
62 which is safe because it is reserved for the implementation. */
63
64#ifdef _BSD_VA_LIST
65#undef _BSD_VA_LIST
66#endif
67
68#if defined(__svr4__) || (defined(_SCO_DS) && !defined(__VA_LIST))
69/* SVR4.2 uses _VA_LIST for an internal alias for va_list,
70 so we must avoid testing it and setting it here.
71 SVR4 uses _VA_LIST as a flag in stdarg.h, but we should
72 have no conflict with that. */
73#ifndef _VA_LIST_
74#define _VA_LIST_
75#ifdef __i860__
76#ifndef _VA_LIST
77#define _VA_LIST va_list
78#endif
79#endif /* __i860__ */
80typedef __gnuc_va_list va_list;
81#ifdef _SCO_DS
82#define __VA_LIST
83#endif
84#endif /* _VA_LIST_ */
85#else /* not __svr4__ || _SCO_DS */
86
87/* The macro _VA_LIST_ is the same thing used by this file in Ultrix.
88 But on BSD NET2 we must not test or define or undef it.
89 (Note that the comments in NET 2's ansi.h
90 are incorrect for _VA_LIST_--see stdio.h!) */
91#if !defined (_VA_LIST_) || defined (__BSD_NET2__) || defined (____386BSD____) || defined (__bsdi__) || defined (__sequent__) || defined (__FreeBSD__) || defined(WINNT)
92/* The macro _VA_LIST_DEFINED is used in Windows NT 3.5 */
93#ifndef _VA_LIST_DEFINED
94/* The macro _VA_LIST is used in SCO Unix 3.2. */
95#ifndef _VA_LIST
96/* The macro _VA_LIST_T_H is used in the Bull dpx2 */
97#ifndef _VA_LIST_T_H
98/* The macro __va_list__ is used by BeOS. */
99#ifndef __va_list__
100typedef __gnuc_va_list va_list;
101#endif /* not __va_list__ */
102#endif /* not _VA_LIST_T_H */
103#endif /* not _VA_LIST */
104#endif /* not _VA_LIST_DEFINED */
105#if !(defined (__BSD_NET2__) || defined (____386BSD____) || defined (__bsdi__) || defined (__sequent__) || defined (__FreeBSD__))
106#define _VA_LIST_
107#endif
108#ifndef _VA_LIST
109#define _VA_LIST
110#endif
111#ifndef _VA_LIST_DEFINED
112#define _VA_LIST_DEFINED
113#endif
114#ifndef _VA_LIST_T_H
115#define _VA_LIST_T_H
116#endif
117#ifndef __va_list__
118#define __va_list__
119#endif
120
121#endif /* not _VA_LIST_, except on certain systems */
122
123#endif /* not __svr4__ */
124
125#endif /* _STDARG_H */
126
127#endif /* not _ANSI_STDARG_H_ */
128#endif /* not _STDARG_H */
Note: See TracBrowser for help on using the repository browser.