On 1/10/07, Jim Jewett <[EMAIL PROTECTED]> wrote:
> On 1/10/07, Collin Winter <[EMAIL PROTECTED]> wrote:
> >     re = get_resource()
> ...
> >     except RareException as re:
> ...
> >     re.use_resource()
>
> > So 're = None; del re;' is *only* executed if the except body is executed.
>
> So re.use_resource() will usually work (as it does today).
>
> The difference is that when it doesn't work, you'll see something
> about NoneType instead the exception type.

You're forgetting about the 'del N'; re.use_resource() will fail with
a NameError at the call site.

Collin Winter
_______________________________________________
Python-3000 mailing list
Python-3000@python.org
http://mail.python.org/mailman/listinfo/python-3000
Unsubscribe: 
http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com

Reply via email to