[Lldb-commits] [PATCH] D149625: [lldb] Refactor SBFileSpec::GetDirectory

Alex Langford via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Tue May 2 10:01:52 PDT 2023


This revision was automatically updated to reflect the committed changes.
Closed by commit rG2bea2d7b070d: [lldb] Refactor SBFileSpec::GetDirectory (authored by bulbazord).

Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D149625

Files:
  lldb/source/API/SBFileSpec.cpp


Index: lldb/source/API/SBFileSpec.cpp
===================================================================
--- lldb/source/API/SBFileSpec.cpp
+++ lldb/source/API/SBFileSpec.cpp
@@ -114,9 +114,7 @@
 const char *SBFileSpec::GetDirectory() const {
   LLDB_INSTRUMENT_VA(this);
 
-  FileSpec directory{*m_opaque_up};
-  directory.ClearFilename();
-  return directory.GetPathAsConstString().GetCString();
+  return m_opaque_up->GetDirectory().GetCString();
 }
 
 void SBFileSpec::SetFilename(const char *filename) {


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D149625.518782.patch
Type: text/x-patch
Size: 510 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20230502/3638a9a5/attachment-0001.bin>


More information about the lldb-commits mailing list