aboutsummaryrefslogtreecommitdiff
path: root/libcpp
diff options
context:
space:
mode:
Diffstat (limited to 'libcpp')
-rw-r--r--libcpp/ChangeLog7
-rw-r--r--libcpp/expr.c8
-rw-r--r--libcpp/init.c2
3 files changed, 13 insertions, 4 deletions
diff --git a/libcpp/ChangeLog b/libcpp/ChangeLog
index 74979a2..7fdc737 100644
--- a/libcpp/ChangeLog
+++ b/libcpp/ChangeLog
@@ -1,3 +1,10 @@
+2009-04-21 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
+
+ PR c++/13358
+ * init.c (cpp_create_reader): Wlong_long is disabled by default.
+ * expr.c (cpp_classify_number): Give different messages for C and
+ C++ front-ends.
+
2009-04-19 Joseph Myers <joseph@codesourcery.com>
PR preprocessor/20078
diff --git a/libcpp/expr.c b/libcpp/expr.c
index 56945d9..b9a17db 100644
--- a/libcpp/expr.c
+++ b/libcpp/expr.c
@@ -419,10 +419,12 @@ cpp_classify_number (cpp_reader *pfile, const cpp_token *token)
}
if ((result & CPP_N_WIDTH) == CPP_N_LARGE
- && ! CPP_OPTION (pfile, c99)
&& CPP_OPTION (pfile, warn_long_long))
- cpp_error (pfile, CPP_DL_PEDWARN,
- "use of C99 long long integer constant");
+ cpp_error (pfile,
+ CPP_OPTION (pfile, c99) ? CPP_DL_WARNING : CPP_DL_PEDWARN,
+ CPP_OPTION (pfile, cplusplus)
+ ? "use of C++0x long long integer constant"
+ : "use of C99 long long integer constant");
result |= CPP_N_INTEGER;
}
diff --git a/libcpp/init.c b/libcpp/init.c
index d251f19..c211217 100644
--- a/libcpp/init.c
+++ b/libcpp/init.c
@@ -160,7 +160,7 @@ cpp_create_reader (enum c_lang lang, hash_table *table,
CPP_OPTION (pfile, warn_trigraphs) = 2;
CPP_OPTION (pfile, warn_endif_labels) = 1;
CPP_OPTION (pfile, warn_deprecated) = 1;
- CPP_OPTION (pfile, warn_long_long) = !CPP_OPTION (pfile, c99);
+ CPP_OPTION (pfile, warn_long_long) = 0;
CPP_OPTION (pfile, dollars_in_ident) = 1;
CPP_OPTION (pfile, warn_dollars) = 1;
CPP_OPTION (pfile, warn_variadic_macros) = 1;