From 45c971f7eef18ef2b77a5f64133dbd7bd5939d5f Mon Sep 17 00:00:00 2001 From: Jonas Devlieghere Date: Thu, 9 Jan 2020 08:15:01 -0800 Subject: [lldb/Lua] Make lldb.debugger et al available to Lua The Python script interpreter makes the current debugger, target, process, thread and frame available to interactive scripting sessions through convenience variables. This patch does the same for Lua. Differential revision: https://reviews.llvm.org/D71801 --- lldb/source/Plugins/ScriptInterpreter/Lua/ScriptInterpreterLua.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'lldb/source/Plugins/ScriptInterpreter/Lua/ScriptInterpreterLua.h') diff --git a/lldb/source/Plugins/ScriptInterpreter/Lua/ScriptInterpreterLua.h b/lldb/source/Plugins/ScriptInterpreter/Lua/ScriptInterpreterLua.h index b34c7d0..550e1035 100644 --- a/lldb/source/Plugins/ScriptInterpreter/Lua/ScriptInterpreterLua.h +++ b/lldb/source/Plugins/ScriptInterpreter/Lua/ScriptInterpreterLua.h @@ -43,8 +43,12 @@ public: Lua &GetLua(); + llvm::Error EnterSession(lldb::user_id_t debugger_id); + llvm::Error LeaveSession(); + private: std::unique_ptr m_lua; + bool m_session_is_active = false; }; } // namespace lldb_private -- cgit v1.1