hakril added the comment: I found something else, I think it worth mentioning it.
This side-effect allows to create generators that return other values that None. And the CPython's behavior is not the same for all versions: >>> {(yield i) : i for i in range(2)} <generator object <dictcomp> at 0x7f0b98f41410> >>> list(_) # python3.(3,4,5) [0, 1] # python3.2 [0, 1, {None: 1}] # python3.2 appends the generator's return value. ---------- versions: +Python 3.2, Python 3.3 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue21964> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com