[Lldb-commits] [lldb] [lldb] Reimplment PyRun_String using the Python stable C API (PR #151761)
Jonas Devlieghere via lldb-commits
lldb-commits at lists.llvm.org
Mon Aug 4 08:29:17 PDT 2025
================
@@ -1469,11 +1466,33 @@ python::runStringMultiLine(const llvm::Twine &string,
const PythonDictionary &locals) {
if (!globals.IsValid() || !locals.IsValid())
return nullDeref();
- PyObject *result = PyRun_String(NullTerminated(string), Py_file_input,
- globals.get(), locals.get());
+ PyObject *result = RunString(NullTerminated(string), Py_file_input,
+ globals.get(), locals.get());
if (!result)
return exception();
return Take<PythonObject>(result);
}
+namespace lldb_private {
+namespace python {
----------------
JDevlieghere wrote:
I thought that rule was primarily aimed at anonymous namespaces, but I guess it applies here too. Regardless, it would be inconsistent which is why I didn't change the whole file. Seems like I'm the only one that prefers the namespaces so I'll change it to use the fully qualified names.
https://github.com/llvm/llvm-project/pull/151761
More information about the lldb-commits
mailing list