@@ -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"
@@ -12993,7 +13013,10 @@ def err_acc_clause_appertainment
1299313013def err_acc_duplicate_clause_disallowed
1299413014 : Error<"OpenACC '%1' clause cannot appear more than once on a '%0' "
1299513015 "directive">;
12996- def note_acc_previous_clause_here : Note<"previous clause is here">;
13016+ def note_acc_previous_clause_here : Note<"previous '%0' clause is here">;
13017+ def note_acc_active_applies_clause_here
13018+ : Note<"%enum_select<ACCDeviceTypeApp>{%Active{active}|%Applies{which "
13019+ "applies to}}0 '%1' clause here">;
1299713020def note_acc_previous_expr_here : Note<"previous expression is here">;
1299813021def note_acc_previous_reference : Note<"previous reference is here">;
1299913022def err_acc_branch_in_out_compute_construct
@@ -13079,6 +13102,9 @@ def err_acc_clause_routine_one_of_in_region
1307913102def err_acc_clause_since_last_device_type
1308013103 : Error<"OpenACC '%0' clause cannot appear more than once%select{| in a "
1308113104 "'device_type' region}2 on a '%1' directive">;
13105+ def err_acc_clause_conflicts_prev_dev_type
13106+ : Error<"OpenACC '%0' clause applies to 'device_type' '%1', which "
13107+ "conflicts with previous '%0' clause">;
1308213108
1308313109def err_acc_reduction_num_gangs_conflict
1308413110 : Error<"OpenACC '%1' clause %select{|with more than 1 argument }0may not "
@@ -13241,7 +13267,7 @@ def err_acc_duplicate_bind
1324113267 "permitted to refer to the same function">;
1324213268def err_acc_duplicate_unnamed_bind
1324313269 : Error<"OpenACC 'bind' clause on a declaration must bind to the same name "
13244- "as previous bind clauses">;
13270+ "as previous ' bind' clauses">;
1324513271def warn_acc_confusing_routine_name
1324613272 : Warning<"OpenACC 'routine' directive with a name refers to a function "
1324713273 "with the same name as the function on the following line; this "
0 commit comments