[PATCH] [modules] PR20507: Avoid silent textual inclusion.
Sean Silva
chisophugis at gmail.com
Fri Jun 19 16:18:24 PDT 2015
================
Comment at: include/clang/Basic/DiagnosticLexKinds.td:626
@@ -625,1 +625,3 @@
+def note_implicit_top_level_module_import_here : Note<
+ "submodule of top-level module '%0' implicitly imported here">;
def warn_uncovered_module_header : Warning<
----------------
benlangmuir wrote:
> I'd just drop "submodule of top-level ".
I think it's an important qualification because the module that was in fact imported is not %0. %0 is the top-level module containing it, and the error is because some submodule of %0 (perhaps the one being imported, perhaps not) has the missing file.
>From a user's perspective: "The header I included didn't ask for %0 to be imported. It asked for this submodule of it". Ideally we would be able to somehow communicate the "unity build" aspect of top-level modules for this to make sense, but I couldn't find a way to fit all that in a diagnostic.
Does that make sense?
http://reviews.llvm.org/D10423
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
More information about the cfe-commits
mailing list