[PATCH] D76385: Allow remapping Clang module include paths

Shafik Yaghmour via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Mar 19 14:15:13 PDT 2020


shafik added inline comments.


================
Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:2487
+  // Return a StringRef to the remapped Path.
+  auto RemapPath = [&](std::string Path) -> std::string {
+    Path = remapDIPath(Path);
----------------
`&` -> `&TheCU` 

We should try to explicitly capture what we use, this will avoid potential bugs where we accidentally modify something we did not mean to capture later on when modifying the code.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D76385/new/

https://reviews.llvm.org/D76385





More information about the cfe-commits mailing list