Guido van Rossum <gu...@python.org> added the comment:
Honestly that code seems poorly thought out. If running it returns -1, an exception was presumably reported, but not necessarily SyntaxError -- so parsing it may not produce an error at all. The functionality needed is in PyRun_InteractiveOneObjectEx(), but that is not public. :-( ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue40939> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com