A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2005-May/053354.html below:

[Python-Dev] Pre-PEP: Unifying try-except and try-finally

[Python-Dev] Pre-PEP: Unifying try-except and try-finally [Python-Dev] Pre-PEP: Unifying try-except and try-finallyTim Peters tim.peters at gmail.com
Wed May 4 22:14:23 CEST 2005
[Reinhold Birkenfeld]
> ...
> I think the behaviour of the "else" clause is much harder to guess,
> mainly when used with the looping constructs.

No, that's obvious <wink>.

What about `else` mixed with try/except/finally?

try:
    A
except:
    B
else:
    C
finally:
    D

If A executes without exception, does D execute before or after C?

I'm not saying we can't make up reasonable answers.  I'm saying they
look more-or-less arbitrary, while the current nested forms are always
clear.
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4