r250140 - [modules] Improve error message on failed module load due to a missing file to

Richard Smith via cfe-commits cfe-commits at lists.llvm.org
Mon Oct 12 18:26:26 PDT 2015


Author: rsmith
Date: Mon Oct 12 20:26:26 2015
New Revision: 250140

URL: http://llvm.org/viewvc/llvm-project?rev=250140&view=rev
Log:
[modules] Improve error message on failed module load due to a missing file to
say which module file referenced the missing file.

Modified:
    cfe/trunk/lib/Serialization/ASTReader.cpp

Modified: cfe/trunk/lib/Serialization/ASTReader.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Serialization/ASTReader.cpp?rev=250140&r1=250139&r2=250140&view=diff
==============================================================================
--- cfe/trunk/lib/Serialization/ASTReader.cpp (original)
+++ cfe/trunk/lib/Serialization/ASTReader.cpp Mon Oct 12 20:26:26 2015
@@ -1948,7 +1948,9 @@ InputFile ASTReader::getInputFile(Module
     if (Complain) {
       std::string ErrorStr = "could not find file '";
       ErrorStr += Filename;
-      ErrorStr += "' referenced by AST file";
+      ErrorStr += "' referenced by AST file '";
+      ErrorStr += F.FileName;
+      ErrorStr += "'";
       Error(ErrorStr.c_str());
     }
     // Record that we didn't find the file.




More information about the cfe-commits mailing list