r304962 - [ODRHash] Make diagnostic message more readable.

Richard Trieu via cfe-commits cfe-commits at lists.llvm.org
Wed Jun 7 21:47:29 PDT 2017


Author: rtrieu
Date: Wed Jun  7 23:47:29 2017
New Revision: 304962

URL: http://llvm.org/viewvc/llvm-project?rev=304962&view=rev
Log:
[ODRHash] Make diagnostic message more readable.

Change the diagnostic message from r304956 to be less confusing by reordering
the flow of information.

Modified:
    cfe/trunk/include/clang/Basic/DiagnosticSerializationKinds.td

Modified: cfe/trunk/include/clang/Basic/DiagnosticSerializationKinds.td
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/DiagnosticSerializationKinds.td?rev=304962&r1=304961&r2=304962&view=diff
==============================================================================
--- cfe/trunk/include/clang/Basic/DiagnosticSerializationKinds.td (original)
+++ cfe/trunk/include/clang/Basic/DiagnosticSerializationKinds.td Wed Jun  7 23:47:29 2017
@@ -175,11 +175,13 @@ def note_module_odr_violation_mismatch_d
   "method %2 with %ordinal3 parameter named %4}1">;
 
 def err_module_odr_violation_mismatch_decl_unknown : Error<
-  "%q0 has different definitions in different modules; first difference is "
-  "%select{definition in module '%2'|defined here}1 found different "
-  "%select{||||static assert|field|method|other}3">;
+  "%q0 %select{with definition in module '%2'|defined here}1 has different "
+  "definitions in different modules; first difference is this "
+  "%select{||||static assert|field|method|unexpected decl}3">;
 def note_module_odr_violation_mismatch_decl_unknown : Note<
-  "but in '%0' found different %select{||||static assert|field|method|other}1">;
+  "but in '%0' found "
+  "%select{||||different static assert|different field|different method|"
+  "another unexpected decl}1">;
 
 def warn_duplicate_module_file_extension : Warning<
   "duplicate module file extension block name '%0'">,




More information about the cfe-commits mailing list