--- /dev/null
+Test for module-related warnings.
+This reuses the files from the modules.m testcase.
+
+RUN: rm -rf %t.dir && mkdir %t.dir
+RUN: cp %p/../Inputs/modules/1.o %p/../Inputs/modules/Foo.pcm %t.dir
+
+RUN: llvm-dsymutil -f -oso-prepend-path=%t.dir -y \
+RUN: %p/dummy-debug-map.map -o %t 2>&1 | FileCheck %s
+
+Module-not-found should be reported only once.
+CHECK: warning: {{.*}}Bar.pcm: No such file or directory
+CHECK-NOT: warning: {{.*}}Bar.pcm: No such file or directory
auto &Obj =
ModuleMap.addDebugMapObject(Path, sys::TimeValue::PosixZeroTime());
auto ErrOrObj = loadObject(ObjHolder, Obj, ModuleMap);
- if (!ErrOrObj) {
- ClangModules.erase(ClangModules.find(Filename));
+ if (!ErrOrObj)
return;
- }
std::unique_ptr<CompileUnit> Unit;