Tim Peters <t...@python.org> added the comment:

Yes, the assignment does "hide the global definition of g".  But this 
determination is made at compile time, not at run time:  an assignment to `g` 
_anywhere_ inside `f()` makes _every_ appearance of `g` within `f()` local to 
`f`.

----------
nosy: +tim.peters

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

Reply via email to