From: Nico Weber Date: Mon, 18 Aug 2014 23:02:03 +0000 (+0000) Subject: Add a warning flag for an existing diagnostic. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9adb1ed30e936006eb8766a2d0fe799ea1a3303b;p=clang Add a warning flag for an existing diagnostic. One more, and the number of flags without a dedicated flag fits in two decimal digits :-) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@215946 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/clang/Basic/DiagnosticSemaKinds.td b/include/clang/Basic/DiagnosticSemaKinds.td index a1b2bc6389..2385f375de 100644 --- a/include/clang/Basic/DiagnosticSemaKinds.td +++ b/include/clang/Basic/DiagnosticSemaKinds.td @@ -2074,7 +2074,8 @@ def err_attribute_aligned_not_power_of_two : Error< def err_attribute_aligned_too_great : Error< "requested alignment must be %0 bytes or smaller">; def warn_redeclaration_without_attribute_prev_attribute_ignored : Warning< - "%q0 redeclared without %1 attribute: previous %1 ignored">; + "%q0 redeclared without %1 attribute: previous %1 ignored">, + InGroup>; def warn_attribute_ignored : Warning<"%0 attribute ignored">, InGroup; def warn_attribute_after_definition_ignored : Warning< diff --git a/test/Misc/warning-flags.c b/test/Misc/warning-flags.c index 69706be283..015b1f9dd5 100644 --- a/test/Misc/warning-flags.c +++ b/test/Misc/warning-flags.c @@ -18,7 +18,7 @@ This test serves two purposes: The list of warnings below should NEVER grow. It should gradually shrink to 0. -CHECK: Warnings without flags (101): +CHECK: Warnings without flags (100): CHECK-NEXT: ext_delete_void_ptr_operand CHECK-NEXT: ext_excess_initializers CHECK-NEXT: ext_excess_initializers_in_char_array_initializer @@ -106,7 +106,6 @@ CHECK-NEXT: warn_pragma_pack_show CHECK-NEXT: warn_property_getter_owning_mismatch CHECK-NEXT: warn_property_types_are_incompatible CHECK-NEXT: warn_readonly_property -CHECK-NEXT: warn_redeclaration_without_attribute_prev_attribute_ignored CHECK-NEXT: warn_register_objc_catch_parm CHECK-NEXT: warn_related_result_type_compatibility_class CHECK-NEXT: warn_related_result_type_compatibility_protocol