Skip to content

Commit 817d3dc

Browse files
qiongsiwuAnthonyLatsis
authored andcommitted
Cherry-pick "Fix build failure and a test."
(cherry picked from commit 23f75b6)
1 parent 0714626 commit 817d3dc

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

clang/test/ClangScanDeps/optimize-vfs-pch-tree.m

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,8 @@
5353
// CHECK-NEXT: "clang-module-deps": [
5454
// CHECK-NEXT: {
5555
// CHECK-NEXT: "context-hash": "{{.*}}",
56-
// CHECK-NEXT: "module-name": "E"
56+
// CHECK-NEXT: "module-name": "E",
57+
// CHECK-NEXT: "exported": "true"
5758
// CHECK-NEXT: }
5859
// CHECK-NEXT: ],
5960
// CHECK-NEXT: "clang-modulemap-file": "[[PREFIX]]/modules/D/module.modulemap",

clang/tools/libclang/CDependencies.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -436,8 +436,8 @@ clang_experimental_DepGraphModule_getModuleDeps(CXDepGraphModule CXDepMod) {
436436
const ModuleDeps &ModDeps = *unwrap(CXDepMod)->ModDeps;
437437
std::vector<std::string> Modules;
438438
Modules.reserve(ModDeps.ClangModuleDeps.size());
439-
for (const ModuleID &MID : ModDeps.ClangModuleDeps)
440-
Modules.push_back(MID.ModuleName + ":" + MID.ContextHash);
439+
for (const auto &Info : ModDeps.ClangModuleDeps)
440+
Modules.push_back(Info.ID.ModuleName + ":" + Info.ID.ContextHash);
441441
return unwrap(CXDepMod)->StrMgr.createCStringsOwned(std::move(Modules));
442442
}
443443

0 commit comments

Comments
 (0)