summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/ScriptInterpreter
diff options
context:
space:
mode:
authorPavel Labath <pavel@labath.sk>2019-11-12 14:33:52 +0100
committerPavel Labath <pavel@labath.sk>2019-11-12 14:39:34 +0100
commit1dfb1a85e7cbc37bf6fff9bb046c6e8be0c26b8e (patch)
tree82e4b0662e82b9beb5925f7f5faf245c314abadd /lldb/source/Plugins/ScriptInterpreter
parent5022a5fcaef9e8e5a739d5794954d67bc6f291a2 (diff)
downloadbcm5719-llvm-1dfb1a85e7cbc37bf6fff9bb046c6e8be0c26b8e.tar.gz
bcm5719-llvm-1dfb1a85e7cbc37bf6fff9bb046c6e8be0c26b8e.zip
[lldb] Fix some warnings in the python plugin
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter')
-rw-r--r--lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h4
-rw-r--r--lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp1
2 files changed, 3 insertions, 2 deletions
diff --git a/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h b/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h
index 05f280ae698..b6d63373b43 100644
--- a/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h
+++ b/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h
@@ -130,7 +130,7 @@ template <typename T> T Take(PyObject *obj) {
assert(!PyErr_Occurred());
T thing(PyRefType::Owned, obj);
assert(thing.IsValid());
- return std::move(thing);
+ return thing;
}
// Retain a reference you have borrowed, and turn it into
@@ -148,7 +148,7 @@ template <typename T> T Retain(PyObject *obj) {
assert(!PyErr_Occurred());
T thing(PyRefType::Borrowed, obj);
assert(thing.IsValid());
- return std::move(thing);
+ return thing;
}
// This class can be used like a utility function to convert from
diff --git a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
index 29509f5b98e..5ed01cf4793 100644
--- a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
+++ b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
@@ -1190,6 +1190,7 @@ bool ScriptInterpreterPythonImpl::ExecuteOneLineWithReturn(
return true;
}
}
+ llvm_unreachable("Fully covered switch!");
}
Status ScriptInterpreterPythonImpl::ExecuteMultipleLines(
OpenPOWER on IntegriCloud