aboutsummaryrefslogtreecommitdiff
path: root/gcc/cppinit.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/cppinit.c')
-rw-r--r--gcc/cppinit.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/cppinit.c b/gcc/cppinit.c
index 93298ef..62da1f3 100644
--- a/gcc/cppinit.c
+++ b/gcc/cppinit.c
@@ -852,6 +852,10 @@ cpp_start_read (pfile, fname)
CPP_OPTION (pfile, trigraphs) = 0;
}
+ /* -Wtraditional is not useful in C++ mode. */
+ if (CPP_OPTION (pfile, cplusplus))
+ CPP_OPTION (pfile, warn_traditional) = 0;
+
/* Set this if it hasn't been set already. */
if (user_label_prefix == NULL)
user_label_prefix = USER_LABEL_PREFIX;