aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Wood <wood@gnu.org>1992-08-15 00:20:19 +0000
committerTom Wood <wood@gnu.org>1992-08-15 00:20:19 +0000
commit26ba9d2636bc01ed5aa65c0d6a2d16d441bfa224 (patch)
tree90a18d2142044f27719229a41b04a9f57cbffefc
parente2aab13d8a41cc85fbfd055fe0d4c4a2f803c6d5 (diff)
downloadgcc-26ba9d2636bc01ed5aa65c0d6a2d16d441bfa224.zip
gcc-26ba9d2636bc01ed5aa65c0d6a2d16d441bfa224.tar.gz
gcc-26ba9d2636bc01ed5aa65c0d6a2d16d441bfa224.tar.bz2
Really install NULL_PTR change
From-SVN: r1854
-rw-r--r--gcc/gcc.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/gcc/gcc.c b/gcc/gcc.c
index dbf72f4..b161350 100644
--- a/gcc/gcc.c
+++ b/gcc/gcc.c
@@ -47,12 +47,22 @@ compilation is specified by a string called a "spec". */
#define X_OK 1
#endif
+/* Define a generic NULL if one hasn't already been defined. */
+
#ifndef NULL
#define NULL 0
#endif
+#ifndef GENERIC_PTR
+#if defined (USE_PROTOTYPES) ? USE_PROTOTYPES : defined (__STDC__)
+#define GENERIC_PTR void *
+#else
+#define GENERIC_PTR char *
+#endif
+#endif
+
#ifndef NULL_PTR
-#define NULL_PTR (char *) NULL
+#define NULL_PTR ((GENERIC_PTR)0)
#endif
#ifdef USG