Declare malloc, free, and atexit if inhibit_libc is defined.
[official-gcc.git] / gcc / gansidecl.h
blobf867cda0426f4edf1e4cb9e1b7f6c007acc6e48d
1 /* ANSI and traditional C compatibility macros.
2 Copyright (C) 1996, 1997, 1998, 1999 Free Software Foundation, Inc.
4 This file is part of GNU CC.
6 GNU CC is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2, or (at your option)
9 any later version.
11 GNU CC is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with GNU CC; see the file COPYING. If not, write to
18 the Free Software Foundation, 59 Temple Place - Suite 330,
19 Boston, MA 02111-1307, USA. */
21 /* This file mimics some of the support provided by include/ansidecl.h
22 in binutils and gdb releases.
23 ??? Over time the two should be merged into one. */
25 #ifndef __GANSIDECL_H__
26 #define __GANSIDECL_H__
28 #include "ansidecl.h"
30 /* Undef ansidecl.h's "obsolete" version. */
31 #undef PROTO
32 /* These macros are deprecated, use ansidecl.h's PARAMS style instead. */
33 #define PROTO(ARGS) PARAMS(ARGS)
34 #define VPROTO(ARGS) VPARAMS(ARGS)
35 #define PVPROTO(ARGS) PARAMS(ARGS)
37 /* Autoconf will possibly define the `inline' or `const' keywords as
38 macros, however this is only valid for the stage1 compiler. If we
39 detect a modern version of gcc, unconditionally reset the values.
40 This makes sure the right thing happens in stage2 and later. We
41 need to do this very early; i.e. before any systems header files or
42 gcc header files in case they use these keywords. Otherwise
43 conflicts might occur. */
44 #if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 7)
45 # undef const
46 # undef inline
47 # define inline __inline__ /* Modern gcc can use `__inline__' freely. */
48 # ifndef HAVE_LONG_DOUBLE
49 # define HAVE_LONG_DOUBLE 1
50 # endif
51 /* Assume that (non-traditional) gcc used in stage2 or later has the
52 stringize feature. */
53 # if !defined (HAVE_STRINGIZE) && __STDC__
54 # define HAVE_STRINGIZE 1
55 # endif /* ! HAVE_STRINGIZE && __STDC__ */
56 #endif /* GCC >= 2.7 */
58 #ifndef NULL_PTR
59 #define NULL_PTR ((PTR) 0)
60 #endif
62 #endif /* __GANSIDECL_H__ */