Changes by Mark Dickinson dicki...@gmail.com:
--
superseder: - except-as in Py3 eats variables
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue12064
___
New submission from Mathias Svensson frea...@freaken.dk:
Current behavior:
In the very simple attached example an existing variable-name is used as the
target in the except-part of a try-statement. The existing variable is deleted
if an exception is throw.
Excepted behavior:
The only
Eric Snow ericsnowcurren...@gmail.com added the comment:
Duplicate of issue8130.
When an exception has been assigned using as target, it is cleared at the end
of the except clause. [1]
See:
[1] http://docs.python.org/py3k/reference/compound_stmts.html#the-try-statement
[2]
Santoso Wijaya santoso.wij...@gmail.com added the comment:
Looks like a regression from 2.x.
On 2.7:
Python 2.7.1 (r271:86832, Nov 27 2010, 17:19:03) [MSC v.1500 64 bit (AMD64)] on
win32
Type help, copyright, credits or license for more information.
e = True
try: raise Exception()
... except
Ezio Melotti ezio.melo...@gmail.com added the comment:
Closing as duplicate.
--
nosy: +ezio.melotti
resolution: - duplicate
stage: - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org