[cfe-commits] r141962 - in /cfe/trunk: include/clang/Basic/DiagnosticSemaKinds.td test/Misc/warning-flags.c
Joerg Sonnenberger
joerg at bec.de
Fri Oct 14 10:34:53 PDT 2011
Author: joerg
Date: Fri Oct 14 12:34:53 2011
New Revision: 141962
URL: http://llvm.org/viewvc/llvm-project?rev=141962&view=rev
Log:
Add flags for the remaining shift related warnings
(-Wshift-count-negative, -Wshift-count-overflow).
Modified:
cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td
cfe/trunk/test/Misc/warning-flags.c
Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td?rev=141962&r1=141961&r2=141962&view=diff
==============================================================================
--- cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td (original)
+++ cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td Fri Oct 14 12:34:53 2011
@@ -3125,8 +3125,10 @@
def warn_division_by_zero : Warning<"division by zero is undefined">;
def warn_remainder_by_zero : Warning<"remainder by zero is undefined">;
-def warn_shift_negative : Warning<"shift count is negative">;
-def warn_shift_gt_typewidth : Warning<"shift count >= width of type">;
+def warn_shift_negative : Warning<"shift count is negative">,
+ InGroup<DiagGroup<"shift-count-negative">>;
+def warn_shift_gt_typewidth : Warning<"shift count >= width of type">,
+ InGroup<DiagGroup<"shift-count-overflow">>;
def warn_shift_result_gt_typewidth : Warning<
"signed shift result (%0) requires %1 bits to represent, but %2 only has "
"%3 bits">, InGroup<DiagGroup<"shift-overflow">>;
Modified: cfe/trunk/test/Misc/warning-flags.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Misc/warning-flags.c?rev=141962&r1=141961&r2=141962&view=diff
==============================================================================
--- cfe/trunk/test/Misc/warning-flags.c (original)
+++ cfe/trunk/test/Misc/warning-flags.c Fri Oct 14 12:34:53 2011
@@ -17,7 +17,7 @@
The list of warnings below should NEVER grow. It should gradually shrink to 0.
-CHECK: Warnings without flags (299):
+CHECK: Warnings without flags (297):
CHECK-NEXT: backslash_newline_space
CHECK-NEXT: charize_microsoft_ext
CHECK-NEXT: ext_anon_param_requires_type_specifier
@@ -288,8 +288,6 @@
CHECK-NEXT: warn_second_parameter_to_va_arg_never_compatible
CHECK-NEXT: warn_setter_getter_impl_required
CHECK-NEXT: warn_setter_getter_impl_required_in_category
-CHECK-NEXT: warn_shift_gt_typewidth
-CHECK-NEXT: warn_shift_negative
CHECK-NEXT: warn_standalone_specifier
CHECK-NEXT: warn_static_inline_explicit_inst_ignored
CHECK-NEXT: warn_static_non_static
More information about the cfe-commits
mailing list