]>
git.ipfire.org Git - thirdparty/bash.git/blob - include/stdc.h
c216a697776e819dee80945cb8db8b81c8c9d3af
1 /* stdc.h -- macros to make source compile on both ANSI C and K&R C
4 /* Copyright (C) 1993 Free Software Foundation, Inc.
6 This file is part of GNU Bash, the Bourne Again SHell.
8 Bash is free software; you can redistribute it and/or modify it
9 under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2, or (at your option)
13 Bash is distributed in the hope that it will be useful, but WITHOUT
14 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
15 or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
16 License for more details.
18 You should have received a copy of the GNU General Public License
19 along with Bash; see the file COPYING. If not, write to the Free
20 Software Foundation, 59 Temple Place, Suite 330, Boston, MA 02111 USA. */
22 #if !defined (_STDC_H_)
25 /* Adapted from BSD /usr/include/sys/cdefs.h. */
27 /* A function can be defined using prototypes and compile on both ANSI C
28 and traditional C compilers with something like this:
29 extern char *func __P((char *, char *, int)); */
32 # if defined (__STDC__) || defined (__GNUC__) || defined (__cplusplus)
33 # define __P(protos) protos
35 # define __P(protos) ()
39 #if defined (__STDC__)
41 # define __STRING(x) #x
43 # if !defined (__GNUC__)
49 # define __STRING(x) "x"
51 #if defined (__GNUC__) /* gcc with -traditional */
53 # define const __const
55 # if !defined (inline)
56 # define inline __inline
58 # if !defined (signed)
59 # define signed __signed
61 # if !defined (volatile)
62 # define volatile __volatile
68 # if !defined (inline)
71 # if !defined (signed)
74 # if !defined (volatile)
77 #endif /* !__GNUC__ */
79 #endif /* !__STDC__ */
81 #endif /* !_STDC_H_ */