Try block problem

Marcin 'Qrczak' Kowalczyk qrczak at
Tue Nov 20 13:53:57 CET 2001

Tue, 20 Nov 2001 05:37:41 -0600, Skip Montanaro <skip at> pisze:

> The thing that is perhaps slightly misleading is the use of the "try"
> keyword to begin both constructs.  There's really no "try" connotation to
> try/finally.

Maybe it's because try:except: would have to be used to simulate
try:finally: if it wasn't available natively.

In other words try:finally: is one of things which do something
non-trivial with exceptions instead of silently propagating them up.

In Haskell the equivalent of try:finally: is called bracket
(it includes initialization).

 __("<  Marcin Kowalczyk * qrczak at

More information about the Python-list mailing list