aboutsummaryrefslogtreecommitdiff
path: root/contrib/llvm-project/lldb/source/Interpreter/ScriptInterpreter.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/llvm-project/lldb/source/Interpreter/ScriptInterpreter.cpp')
-rw-r--r--contrib/llvm-project/lldb/source/Interpreter/ScriptInterpreter.cpp21
1 files changed, 18 insertions, 3 deletions
diff --git a/contrib/llvm-project/lldb/source/Interpreter/ScriptInterpreter.cpp b/contrib/llvm-project/lldb/source/Interpreter/ScriptInterpreter.cpp
index 2722666439bf..fb3fa74d0b97 100644
--- a/contrib/llvm-project/lldb/source/Interpreter/ScriptInterpreter.cpp
+++ b/contrib/llvm-project/lldb/source/Interpreter/ScriptInterpreter.cpp
@@ -29,10 +29,8 @@ using namespace lldb_private;
ScriptInterpreter::ScriptInterpreter(
Debugger &debugger, lldb::ScriptLanguage script_lang,
- lldb::ScriptedProcessInterfaceUP scripted_process_interface_up,
lldb::ScriptedPlatformInterfaceUP scripted_platform_interface_up)
: m_debugger(debugger), m_script_lang(script_lang),
- m_scripted_process_interface_up(std::move(scripted_process_interface_up)),
m_scripted_platform_interface_up(
std::move(scripted_platform_interface_up)) {}
@@ -82,6 +80,22 @@ ScriptInterpreter::GetDataExtractorFromSBData(const lldb::SBData &data) const {
return data.m_opaque_sp;
}
+lldb::BreakpointSP ScriptInterpreter::GetOpaqueTypeFromSBBreakpoint(
+ const lldb::SBBreakpoint &breakpoint) const {
+ return breakpoint.m_opaque_wp.lock();
+}
+
+lldb::ProcessAttachInfoSP ScriptInterpreter::GetOpaqueTypeFromSBAttachInfo(
+ const lldb::SBAttachInfo &attach_info) const {
+ return attach_info.m_opaque_sp;
+}
+
+lldb::ProcessLaunchInfoSP ScriptInterpreter::GetOpaqueTypeFromSBLaunchInfo(
+ const lldb::SBLaunchInfo &launch_info) const {
+ return std::make_shared<ProcessLaunchInfo>(
+ *reinterpret_cast<ProcessLaunchInfo *>(launch_info.m_opaque_sp.get()));
+}
+
Status
ScriptInterpreter::GetStatusFromSBError(const lldb::SBError &error) const {
if (error.m_opaque_up)
@@ -114,7 +128,8 @@ Status ScriptInterpreter::SetBreakpointCommandCallback(
const char *callback_text) {
Status error;
for (BreakpointOptions &bp_options : bp_options_vec) {
- error = SetBreakpointCommandCallback(bp_options, callback_text);
+ error = SetBreakpointCommandCallback(bp_options, callback_text,
+ /*is_callback=*/false);
if (!error.Success())
break;
}