[Lldb-commits] [llvm] [clang-tools-extra] [lldb] [clang] Add new API in SBTarget for loading core from SBFile (PR #71769)
Greg Clayton via lldb-commits
lldb-commits at lists.llvm.org
Wed Nov 15 11:24:14 PST 2023
================
@@ -627,7 +628,7 @@ class Target : public std::enable_shared_from_this<Target>,
// used.
const lldb::ProcessSP &CreateProcess(lldb::ListenerSP listener_sp,
llvm::StringRef plugin_name,
- const FileSpec *crash_file,
+ lldb::FileSP crash_file,
bool can_connect);
----------------
clayborg wrote:
I think we can have two interfaces in Target.h:
- the previous one that taks a "const FileSpec *"
- the new one that takes a lldb::FileSP
We have a 4 locations that have to manually create a file the code:
```
auto file = FileSystem::Instance().Open(
filespec, lldb_private::File::eOpenOptionReadOnly);
...
```
This will also help reduce the number of changes in this patch. Then the version that takes a "const FileSpec *" can do the `FileSystem::Instance().Open(...)` and just call the other overload that takes a `lldb::FileSP`
https://github.com/llvm/llvm-project/pull/71769
More information about the lldb-commits
mailing list