summaryrefslogtreecommitdiff
path: root/gcc/cpphash.h
diff options
context:
space:
mode:
authorneil <neil@138bc75d-0d04-0410-961f-82ee72b054a4>2000-08-18 17:35:58 +0000
committerneil <neil@138bc75d-0d04-0410-961f-82ee72b054a4>2000-08-18 17:35:58 +0000
commitb39543663166f6d9eabb27b9119cc3f301f487f9 (patch)
treef25ad3759703df13e0d6b40b621ea7e6d2e1dd18 /gcc/cpphash.h
parent68878c92d58709d9a1fa3e95d80a791a79450d75 (diff)
downloadgcc-b39543663166f6d9eabb27b9119cc3f301f487f9.tar.gz
* cpphash.h: Use HAVE_DESIGNATED_INITIALIZERS.
(_cpp_trigraph_map): Declaration moved from cpplex.c * cppinit.c: Define _cpp_trigraph_map. Use UCHAR_MAX + 1 instead of 256. Use consistent test for designated initializers. (cpp_init): Initialize trigraph_map. (initialize_standard_includes, parse_option): Use memcmp instead of strncmp. * cpplex.c (init_trigraph_map): Remove. (trigraph_ok, trigraph_replace, lex_line): Refer to _cpp_trigraph_map. * cpplib.c (str_match, WARNING, ERROR, ICE): Delete. (do_unassert): Remove unused "next" local. * system.h (HAVE_DESIGNATED_INITIALIZERS): New prototype. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@35789 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cpphash.h')
-rw-r--r--gcc/cpphash.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/gcc/cpphash.h b/gcc/cpphash.h
index c5b024427ec..b2f5c1dd619 100644
--- a/gcc/cpphash.h
+++ b/gcc/cpphash.h
@@ -165,13 +165,15 @@ struct spec_nodes
#define is_nvspace(x) ((_cpp_IStable[x] & (ISspace | ISvspace)) == ISspace)
#define is_space(x) (_cpp_IStable[x] & ISspace)
-/* This table is constant if it can be initialized at compile time,
+/* These tables are constant if they can be initialized at compile time,
which is the case if cpp was compiled with GCC >=2.7, or another
compiler that supports C99. */
-#if (GCC_VERSION >= 2007) || (__STDC_VERSION__ >= 199901L)
-extern const unsigned char _cpp_IStable[256];
+#if HAVE_DESIGNATED_INITIALIZERS
+extern const unsigned char _cpp_IStable[UCHAR_MAX + 1];
+extern const unsigned char _cpp_trigraph_map[UCHAR_MAX + 1];
#else
-extern unsigned char _cpp_IStable[256];
+extern unsigned char _cpp_IStable[UCHAR_MAX + 1];
+extern unsigned char _cpp_trigraph_map[UCHAR_MAX + 1];
#endif
/* Macros. */