STINNER Victor added the comment: I suggest to remove the micro-optimization from Python 3.5 for safety.
I'm ok to experiment a new safer implementation on Python 3.6 ;-) We have more time to fix the code in Python 3.6 if new issues are found. Setting the tuple size to zero looks simple and safe, but the overall hack deserves a comment to explain: * why you use a cached tuple * why the reference count can be different than 2: recursive calls * why do you change the tuple size ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue26811> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com