[clang] [C23] More improved type compatibility for enumerations (PR #150946)

Aaron Ballman via cfe-commits cfe-commits at lists.llvm.org
Tue Jul 29 08:50:04 PDT 2025


================
@@ -511,6 +511,14 @@ def note_odr_number_of_bases : Note<
   "class has %0 base %plural{1:class|:classes}0">;
 def note_odr_enumerator : Note<"enumerator %0 with value %1 here">;
 def note_odr_missing_enumerator : Note<"no corresponding enumerator here">;
+def note_odr_incompatible_fixed_underlying_type : Note<
+  "enumeration %0 declared with incompatible fixed underlying types (%1 vs. "
+  "%2)">;
+def note_odr_fixed_underlying_type : Note<
+  "enumeration %0 has fixed underlying type here">;
+def note_odr_missing_fixed_underlying_type : Note<
+  "enumeration %0 missing fixed underlying type here">;
----------------
AaronBallman wrote:

You're not blind, these aren't being tested; I'm the blind one (I saw the similar wording in the error diagnostics and mistook that for testing the notes)!

https://github.com/llvm/llvm-project/pull/150946


More information about the cfe-commits mailing list