@@ -6541,6 +6541,16 @@ def warn_missing_braces : Warning<
65416541 "suggest braces around initialization of subobject">,
65426542 InGroup<MissingBraces>, DefaultIgnore;
65436543
6544+ // This diagnostic exists only to determine whether -Wc++-compat was explicitly
6545+ // enabled. This allows us to tell the difference between when a diagnostic was
6546+ // enabled by default, was enabled because its subgroup was enabled, or enabled
6547+ // because the -Wc++-compat superset was enabled, generally for purposes of
6548+ // deciding whether to emit "and is incompatible with C++" on diagnostics which
6549+ // are useful in C alone as well as for compatibility checks.
6550+ def warn_cxx_compat_hack_fake_diagnostic_do_not_emit : Warning<
6551+ "if you see this diagnostic, a Clang developer has made a mistake">,
6552+ InGroup<CXXCompat>, DefaultIgnore;
6553+
65446554def err_redefinition_of_label : Error<"redefinition of label %0">;
65456555def err_undeclared_label_use : Error<"use of undeclared label %0">;
65466556def err_goto_ms_asm_label : Error<
@@ -6561,18 +6571,28 @@ def ext_goto_into_protected_scope : ExtWarn<
65616571def warn_cxx98_compat_goto_into_protected_scope : Warning<
65626572 "jump from this goto statement to its label is incompatible with C++98">,
65636573 InGroup<CXX98Compat>, DefaultIgnore;
6574+ def warn_cpp_compat_goto_into_protected_scope : Warning<
6575+ "jump from this goto statement to its label is incompatible with C++">,
6576+ InGroup<JumpBypassesInit>, DefaultIgnore;
65646577def err_switch_into_protected_scope : Error<
65656578 "cannot jump from switch statement to this case label">;
65666579def warn_cxx98_compat_switch_into_protected_scope : Warning<
65676580 "jump from switch statement to this case label is incompatible with C++98">,
65686581 InGroup<CXX98Compat>, DefaultIgnore;
6582+ def warn_cpp_compat_switch_into_protected_scope : Warning<
6583+ "jump from switch statement to this case label is incompatible with C++">,
6584+ InGroup<JumpBypassesInit>, DefaultIgnore;
65696585def err_indirect_goto_without_addrlabel : Error<
65706586 "indirect goto in function with no address-of-label expressions">;
65716587def err_indirect_goto_in_protected_scope : Error<
65726588 "cannot jump from this %select{indirect|asm}0 goto statement to one of its possible targets">;
65736589def warn_cxx98_compat_indirect_goto_in_protected_scope : Warning<
65746590 "jump from this %select{indirect|asm}0 goto statement to one of its possible targets "
65756591 "is incompatible with C++98">, InGroup<CXX98Compat>, DefaultIgnore;
6592+ def warn_cpp_compat_indirect_goto_in_protected_scope : Warning<
6593+ "jump from this %select{indirect|asm}0 goto statement to one of its possible "
6594+ "targets is incompatible with C++">,
6595+ InGroup<JumpBypassesInit>, DefaultIgnore;
65766596def note_indirect_goto_target : Note<
65776597 "possible target of %select{indirect|asm}0 goto statement">;
65786598def note_protected_by_variable_init : Note<
@@ -8234,11 +8254,11 @@ def warn_default_init_const : Warning<
82348254 InGroup<DefaultConstInitVar>, DefaultIgnore;
82358255def warn_default_init_const_field_unsafe : Warning<
82368256 "default initialization of an object of type %0 with const member leaves the "
8237- "object uninitialized and is incompatible with C++">,
8257+ "object uninitialized%select{| and is incompatible with C++}1 ">,
82388258 InGroup<DefaultConstInitFieldUnsafe>;
82398259def warn_default_init_const_unsafe : Warning<
82408260 "default initialization of an object of type %0 leaves the object "
8241- "uninitialized and is incompatible with C++">,
8261+ "uninitialized%select{| and is incompatible with C++}1 ">,
82428262 InGroup<DefaultConstInitVarUnsafe>;
82438263def err_default_init_const : Error<
82448264 "default initialization of an object of const type %0"
@@ -12989,7 +13009,10 @@ def err_acc_clause_appertainment
1298913009def err_acc_duplicate_clause_disallowed
1299013010 : Error<"OpenACC '%1' clause cannot appear more than once on a '%0' "
1299113011 "directive">;
12992- def note_acc_previous_clause_here : Note<"previous clause is here">;
13012+ def note_acc_previous_clause_here : Note<"previous '%0' clause is here">;
13013+ def note_acc_active_applies_clause_here
13014+ : Note<"%enum_select<ACCDeviceTypeApp>{%Active{active}|%Applies{which "
13015+ "applies to}}0 '%1' clause here">;
1299313016def note_acc_previous_expr_here : Note<"previous expression is here">;
1299413017def note_acc_previous_reference : Note<"previous reference is here">;
1299513018def err_acc_branch_in_out_compute_construct
@@ -13075,6 +13098,9 @@ def err_acc_clause_routine_one_of_in_region
1307513098def err_acc_clause_since_last_device_type
1307613099 : Error<"OpenACC '%0' clause cannot appear more than once%select{| in a "
1307713100 "'device_type' region}2 on a '%1' directive">;
13101+ def err_acc_clause_conflicts_prev_dev_type
13102+ : Error<"OpenACC '%0' clause applies to 'device_type' '%1', which "
13103+ "conflicts with previous '%0' clause">;
1307813104
1307913105def err_acc_reduction_num_gangs_conflict
1308013106 : Error<"OpenACC '%1' clause %select{|with more than 1 argument }0may not "
@@ -13237,7 +13263,7 @@ def err_acc_duplicate_bind
1323713263 "permitted to refer to the same function">;
1323813264def err_acc_duplicate_unnamed_bind
1323913265 : Error<"OpenACC 'bind' clause on a declaration must bind to the same name "
13240- "as previous bind clauses">;
13266+ "as previous ' bind' clauses">;
1324113267def warn_acc_confusing_routine_name
1324213268 : Warning<"OpenACC 'routine' directive with a name refers to a function "
1324313269 "with the same name as the function on the following line; this "
0 commit comments