[New-bugs-announce] [issue6833] incorrect: failed local variable referenced before assignment

Paul van der Linden report at bugs.python.org
Thu Sep 3 13:25:32 CEST 2009


New submission from Paul van der Linden <paul at soulbase.nl>:

The attached python file will give the following output, which is 
incorrect behavior as far as I know:
"
this will fail
failed local variable 'in_std' referenced before assignment

this won't fail
Not failed
this won't fail either
Not failed
"

This is tested on windows with python2.6(standard msi) and on centos 
5.3 with python2.6 (custom rpm), python2.4 (system rpm), freebsd with 
python2.5 (system package), python2.6 ("hand" compiled) and python3.0 
("hand" compiled).

The attached code is stripped down to the bare minimum and therefore 
won't do anything usefull.

----------
components: None
files: bug.py
messages: 92199
nosy: paultjuhatwork
severity: normal
status: open
title: incorrect: failed local variable referenced before assignment
type: behavior
versions: Python 2.4, Python 2.5, Python 2.6, Python 3.0
Added file: http://bugs.python.org/file14825/bug.py

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue6833>
_______________________________________


More information about the New-bugs-announce mailing list