Serhiy Storchaka added the comment: PyList_GET_SIZE(list) is cheap (especially in comparison of _PyDict_GetItemId(), _PyDict_SetItemId() and PyList_New()), and its tiny overhead can be avoided at most once per thread's lifetime. I'm sure you can't measure the effect of this change.
If surrounding code be modified for other reasons, may be your change could be applied. But it alone just makes a code churn. ---------- nosy: +rhettinger, serhiy.storchaka _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue31187> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com