[Lldb-commits] [PATCH] D104405: Change PathMappingList::FindFile to return an optional result (NFC)

Shafik Yaghmour via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Fri Jun 25 22:47:10 PDT 2021


shafik accepted this revision.
shafik added a comment.
This revision is now accepted and ready to land.

LGTM



================
Comment at: lldb/source/Core/SourceManager.cpp:444
       if (!FileSystem::Instance().Exists(m_file_spec)) {
-        FileSpec new_file_spec;
         // Check target specific source remappings first, then fall back to
         // modules objects can have individual path remappings that were
----------------
This whole comment reads awkward and does not totally make sense and ends with `. then`


================
Comment at: lldb/source/Target/PathMappingList.cpp:231
     if (orig_ref.consume_front(prefix_ref)) {
       new_spec.SetFile(entry.second.GetCString(), FileSpec::Style::native);
       new_spec.AppendPathComponent(orig_ref);
----------------
Make sense to move `FileSpec new_spec;` declaration down to here.


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

https://reviews.llvm.org/D104405



More information about the lldb-commits mailing list