diff options
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python')
-rw-r--r-- | lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h | 2 | ||||
-rw-r--r-- | lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h b/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h index b75045b..2bab326 100644 --- a/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h +++ b/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h @@ -595,7 +595,7 @@ public: // safe, returns invalid on error; static PythonModule ImportModule(llvm::StringRef name) { - std::string s = name; + std::string s = std::string(name); auto mod = Import(s.c_str()); if (!mod) { llvm::consumeError(mod.takeError()); diff --git a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp index ce4fb30..95a686d 100644 --- a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp +++ b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp @@ -853,7 +853,7 @@ static std::string GenerateUniqueName(const char *base_name_wanted, else sstr.Printf("%s_%p", base_name_wanted, name_token); - return sstr.GetString(); + return std::string(sstr.GetString()); } bool ScriptInterpreterPythonImpl::GetEmbeddedInterpreterModuleObjects() { @@ -3035,7 +3035,7 @@ bool ScriptInterpreterPythonImpl::GetDocumentationForItem(const char *item, StreamString str_stream; str_stream.Printf( "Function %s was not found. Containing module might be missing.", item); - dest = str_stream.GetString(); + dest = std::string(str_stream.GetString()); return false; } } |