New submission from Michael R Bax <mr...@users.sourceforge.net>:

PEP 289 states that "Python 2.4 and beyond should issue a deprecation 
warning if a list comprehension's loop variable has the same name as a 
variable used in the immediately surrounding scope".  But no warning is 
shown when running
    for x in [ 0 ]: print [ x for x in [ 1 ] ]
in Python 2.5.2 (at least).

----------
components: Interpreter Core
messages: 90952
nosy: mrbax
severity: normal
status: open
title: No deprecation warning for list comprehension leak conflict
type: behavior
versions: Python 2.5

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

Reply via email to