Steve Holden added the comment:

Indeed the issue is that the pointer is to the local variable rather than its 
value at time of closure defnition. Not being familiar with the way cells are 
used, I am unsure as to how the closure keeps the whole namespace alive (that 
would seem to require a frame rather than just a simple cell).

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue21904>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to