Terry J. Reedy <tjre...@udel.edu> added the comment: If ast_parse returns, a correct tree (A) rather than a buggy tree is a hard requirement. If ast_parse does not return, an exception (B) rather than a crash is strongly desired. We should not risk A to get B. I presume that Serhiy is suggesting that option 1 either has such a risk or would consume developer resources that might be better spent on other improvements.
For Python, option 2, seems pretty useless for real code because there are much better ways to sum a long sequence: sum(iterable_of_numbers), seq.append, ''.join(iterable_of_string). Possible addition to the ast.parse entry. "Syntactically correct but extremely long or complex source strings may result in a RecursionError or program crash." ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue32758> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com