Python Forum

Full Version: PyRun_String equivalent in stable ABI
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I'd like to translate a Python/C++ project to the stable ABI. The project uses PyRun_String to exec/eval a literal string in Python. That function is not part of the stable ABI. Is there a recommended workaround?
I would try PyEvalCode() after Py_CompileString(). Both are in the stable ABI.
(Sep-19-2023, 09:43 AM)Gribouillis Wrote: [ -> ]I would try PyEvalCode() after Py_CompileString(). Both are in the stable ABI.

Thanks, this does the trick!