Fredrik Lundh wrote: > Steve Holden wrote: > > >>>access it, and catch the NameError: >>> >>> try: >>> variable >>> except NameError: >> >>In a function when accessing a not-yet-bound local variable you may also >>(as Fredrik knows but didn't bother to say) see an UnboundLocalError >>exception, > > > >>> issubclass(UnboundLocalError, NameError) > True > > >>> # muhaha! > Cool.
regards Steve -- Steve Holden +44 150 684 7255 +1 800 494 3119 Holden Web LLC/Ltd http://www.holdenweb.com Skype: holdenweb http://holdenweb.blogspot.com Recent Ramblings http://del.icio.us/steve.holden -- http://mail.python.org/mailman/listinfo/python-list