[PATCH] D86230: [SourceManager] Skip module maps when searching files for macro arguments

Duncan P. N. Exon Smith via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Oct 22 13:04:28 PDT 2020


dexonsmith added inline comments.


================
Comment at: clang/lib/Basic/SourceManager.cpp:1764
     if (Entry.isFile()) {
-      SourceLocation IncludeLoc = Entry.getFile().getIncludeLoc();
+      auto File = Entry.getFile();
+      if (File.getFileCharacteristic() == C_User_ModuleMap ||
----------------
It seems unintentinoal to copy out the `FileInfo` here. Should this be a reference?
```
auto &File = Entry.getFile();
```


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D86230



More information about the cfe-commits mailing list