aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorTom Wood <wood@gnu.org>1992-08-14 23:36:43 +0000
committerTom Wood <wood@gnu.org>1992-08-14 23:36:43 +0000
commit390e01bf6cf8c2322a558ed62fd4c213c8cd6fc6 (patch)
treec00fbcebe409f061f82fd3e8e0a95c62451cc0b9 /gcc
parentc7d26bc1273c05c881198c4e34defe866898830d (diff)
downloadgcc-390e01bf6cf8c2322a558ed62fd4c213c8cd6fc6.zip
gcc-390e01bf6cf8c2322a558ed62fd4c213c8cd6fc6.tar.gz
gcc-390e01bf6cf8c2322a558ed62fd4c213c8cd6fc6.tar.bz2
(NULL_PTR): Use the same definition as
rtl.h and tree.h. From-SVN: r1852
Diffstat (limited to 'gcc')
-rw-r--r--gcc/cccp.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/gcc/cccp.c b/gcc/cccp.c
index 79bb816..a6b1250 100644
--- a/gcc/cccp.c
+++ b/gcc/cccp.c
@@ -130,18 +130,24 @@ typedef struct { unsigned :16, :16, :16; } vms_ino_t;
#define S_ISREG(m) (((m) & S_IFMT) == S_IFREG)
#endif
+/* Define a generic NULL if one hasn't already been defined. */
+
#ifndef NULL
#define NULL 0
#endif
-#ifndef NULL_PTR
-#ifdef __STDC__
-#define NULL_PTR (void *) NULL
+#ifndef GENERIC_PTR
+#if defined (USE_PROTOTYPES) ? USE_PROTOTYPES : defined (__STDC__)
+#define GENERIC_PTR void *
#else
-#define NULL_PTR (char *) NULL
+#define GENERIC_PTR char *
#endif
#endif
+#ifndef NULL_PTR
+#define NULL_PTR ((GENERIC_PTR)0)
+#endif
+
#ifndef INCLUDE_LEN_FUDGE
#define INCLUDE_LEN_FUDGE 0
#endif