This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author adrianmay
Recipients adrianmay
Date 2010-01-21.07:32:36
SpamBayes Score 3.0267455e-12
Marked as misclassified No
Message-id <1264059159.7.0.610108234991.issue7747@psf.upfronthosting.co.za>
In-reply-to
Content
Hi folks,

The attached program says:

$ ./bug.py
a
None
b
Traceback (most recent call last):
  File "./bug.py", line 49, in <module>
    print number(s)
  File "./bug.py", line 34, in foo
    while eat != None:
UnboundLocalError: local variable 'eat' referenced before assignment

but I reckon it is assigned. (I haven't tried it on a newer python because the junk I want to use with python says it only works with 2.5.2.) 

Cheers, Adrian.
History
Date User Action Args
2010-01-21 07:32:39adrianmaysetrecipients: + adrianmay
2010-01-21 07:32:39adrianmaysetmessageid: <1264059159.7.0.610108234991.issue7747@psf.upfronthosting.co.za>
2010-01-21 07:32:37adrianmaylinkissue7747 messages
2010-01-21 07:32:37adrianmaycreate