[Lldb-commits] [PATCH] D106723: [source maps] fix source mapping when there are multiple matching rules
Greg Clayton via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Fri Jul 23 17:44:49 PDT 2021
clayborg added inline comments.
================
Comment at: lldb/include/lldb/Target/PathMappingList.h:75
///
+ /// \param[in] check_filesystem
+ /// If \b true, besides matching \p path with the remapping rules, this tries
----------------
"only_if_exists" be a better name for "check_filesystem"
================
Comment at: lldb/source/Target/PathMappingList.cpp:168
llvm::Optional<FileSpec>
-PathMappingList::RemapPath(llvm::StringRef path) const {
+PathMappingList::RemapPath(llvm::StringRef path, bool check_filesystem) const {
if (m_pairs.empty() || path.empty())
----------------
Would "only_if_exists" be a better name for "check_filesystem"?
================
Comment at: lldb/source/Target/PathMappingList.cpp:217
llvm::Optional<FileSpec> PathMappingList::FindFile(const FileSpec &orig_spec) const {
- if (auto remapped = RemapPath(orig_spec.GetPath()))
- if (FileSystem::Instance().Exists(*remapped))
+ if (auto remapped = RemapPath(orig_spec.GetPath(), /*check_filesystem=*/true))
return remapped;
----------------
"only_if_exists" be a better name for "check_filesystem
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D106723/new/
https://reviews.llvm.org/D106723
More information about the lldb-commits
mailing list