aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPythonImpl.h
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPythonImpl.h')
-rw-r--r--lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPythonImpl.h24
1 files changed, 13 insertions, 11 deletions
diff --git a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPythonImpl.h b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPythonImpl.h
index 1b3a1bf..373513f 100644
--- a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPythonImpl.h
+++ b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPythonImpl.h
@@ -294,17 +294,19 @@ public:
TearDownSession = 0x0004
};
- Locker(ScriptInterpreterPythonImpl *py_interpreter = nullptr,
+ Locker(ScriptInterpreterPythonImpl *py_interpreter,
uint16_t on_entry = AcquireLock | InitSession,
- uint16_t on_leave = FreeLock | TearDownSession, FILE *in = nullptr,
- FILE *out = nullptr, FILE *err = nullptr);
+ uint16_t on_leave = FreeLock | TearDownSession,
+ lldb::FileSP in = nullptr, lldb::FileSP out = nullptr,
+ lldb::FileSP err = nullptr);
~Locker() override;
private:
bool DoAcquireLock();
- bool DoInitSession(uint16_t on_entry_flags, FILE *in, FILE *out, FILE *err);
+ bool DoInitSession(uint16_t on_entry_flags, lldb::FileSP in,
+ lldb::FileSP out, lldb::FileSP err);
bool DoFreeLock();
@@ -312,7 +314,6 @@ public:
bool m_teardown_session;
ScriptInterpreterPythonImpl *m_python_interpreter;
- // FILE* m_tmp_fh;
PyGILState_STATE m_GILState;
};
@@ -341,7 +342,8 @@ public:
static void AddToSysPath(AddLocation location, std::string path);
- bool EnterSession(uint16_t on_entry_flags, FILE *in, FILE *out, FILE *err);
+ bool EnterSession(uint16_t on_entry_flags, lldb::FileSP in, lldb::FileSP out,
+ lldb::FileSP err);
void LeaveSession();
@@ -369,12 +371,12 @@ public:
bool GetEmbeddedInterpreterModuleObjects();
- bool SetStdHandle(File &file, const char *py_name, PythonFile &save_file,
- const char *mode);
+ bool SetStdHandle(lldb::FileSP file, const char *py_name,
+ PythonObject &save_file, const char *mode);
- PythonFile m_saved_stdin;
- PythonFile m_saved_stdout;
- PythonFile m_saved_stderr;
+ PythonObject m_saved_stdin;
+ PythonObject m_saved_stdout;
+ PythonObject m_saved_stderr;
PythonObject m_main_module;
PythonDictionary m_session_dict;
PythonDictionary m_sys_module_dict;