From c0981da47d5696fe36474fcf86b4ce03ae3ff818 Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Fri, 19 Nov 2021 21:06:13 +0100 Subject: Vendor import of llvm-project main llvmorg-14-init-10186-gff7f2cfa959b. --- .../Python/ScriptedProcessPythonInterface.h | 25 ++++++++++------------ 1 file changed, 11 insertions(+), 14 deletions(-) (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.h') diff --git a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.h b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.h index 30cb5a882af2..421bdd59887c 100644 --- a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.h +++ b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptedProcessPythonInterface.h @@ -13,17 +13,18 @@ #if LLDB_ENABLE_PYTHON +#include "ScriptedPythonInterface.h" #include "lldb/Interpreter/ScriptedProcessInterface.h" namespace lldb_private { -class ScriptInterpreterPythonImpl; -class ScriptedProcessPythonInterface : public ScriptedProcessInterface { +class ScriptedProcessPythonInterface : public ScriptedProcessInterface, + public ScriptedPythonInterface { public: - ScriptedProcessPythonInterface(ScriptInterpreterPythonImpl &interpreter) - : ScriptedProcessInterface(), m_interpreter(interpreter) {} + ScriptedProcessPythonInterface(ScriptInterpreterPythonImpl &interpreter); StructuredData::GenericSP - CreatePluginObject(const llvm::StringRef class_name, lldb::TargetSP target_sp, + CreatePluginObject(const llvm::StringRef class_name, + ExecutionContext &exe_ctx, StructuredData::DictionarySP args_sp) override; Status Launch() override; @@ -34,8 +35,9 @@ public: Status Stop() override; - lldb::MemoryRegionInfoSP - GetMemoryRegionContainingAddress(lldb::addr_t address) override; + llvm::Optional + GetMemoryRegionContainingAddress(lldb::addr_t address, + Status &error) override; StructuredData::DictionarySP GetThreadWithID(lldb::tid_t tid) override; @@ -50,15 +52,10 @@ public: bool IsAlive() override; -protected: - llvm::Optional - GetGenericInteger(llvm::StringRef method_name); - Status GetStatusFromMethod(llvm::StringRef method_name); + llvm::Optional GetScriptedThreadPluginName() override; private: - // The lifetime is managed by the ScriptInterpreter - ScriptInterpreterPythonImpl &m_interpreter; - StructuredData::GenericSP m_object_instance_sp; + lldb::ScriptedThreadInterfaceSP GetScriptedThreadInterface() override; }; } // namespace lldb_private -- cgit v1.2.3