[cfe-commits] r168077 - in /cfe/trunk: lib/Lex/ModuleMap.cpp test/Modules/Inputs/module.map

Douglas Gregor dgregor at apple.com
Thu Nov 15 11:47:16 PST 2012


Author: dgregor
Date: Thu Nov 15 13:47:16 2012
New Revision: 168077

URL: http://llvm.org/viewvc/llvm-project?rev=168077&view=rev
Log:
If an excluded header does not exist, just ignore it

Modified:
    cfe/trunk/lib/Lex/ModuleMap.cpp
    cfe/trunk/test/Modules/Inputs/module.map

Modified: cfe/trunk/lib/Lex/ModuleMap.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/ModuleMap.cpp?rev=168077&r1=168076&r2=168077&view=diff
==============================================================================
--- cfe/trunk/lib/Lex/ModuleMap.cpp (original)
+++ cfe/trunk/lib/Lex/ModuleMap.cpp Thu Nov 15 13:47:16 2012
@@ -1307,7 +1307,9 @@
       if (BuiltinFile)
         Map.addHeader(ActiveModule, BuiltinFile, Exclude);
     }
-  } else {
+  } else if (!Exclude) {
+    // Ignore excluded header files. They're optional anyway.
+    
     Diags.Report(FileNameLoc, diag::err_mmap_header_not_found)
       << Umbrella << FileName;
     HadError = true;

Modified: cfe/trunk/test/Modules/Inputs/module.map
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Modules/Inputs/module.map?rev=168077&r1=168076&r2=168077&view=diff
==============================================================================
--- cfe/trunk/test/Modules/Inputs/module.map (original)
+++ cfe/trunk/test/Modules/Inputs/module.map Thu Nov 15 13:47:16 2012
@@ -63,6 +63,7 @@
 module redecl_merge_top { 
   header "redecl-merge-top.h"
   explicit module Explicit { header "redecl-merge-top-explicit.h" }
+  exclude header "nonexistent.h"
 }
 module redecl_merge_left { 
   header "redecl-merge-left.h" 





More information about the cfe-commits mailing list