[Python-ideas] Minimalist `except` syntax.

Daniel Fetchinson fetchinson at googlemail.com
Sun Oct 18 12:26:24 CEST 2009

> Often I do:
> try:
>     some_suite()
> except SomeError:
>     pass
> What I suggest is that instead we'll have this:
> try:
>     some_suite()
> except SomeError
> What do you think?

Since the sole purpose of your proposal is saving 6 keystrokes I don't
think it's a useful one. I do also lot of times the construct you
mention but it doesn't bother me that I have to type the extra 6
keystrokes. In general, if the sole purpose of a proposal is saving a
couple of keystrokes and nothing else in terms of readability,
maintainability, expressiveness, etc, then I think the proposal is
doomed to fail and rightly so.


Psss, psss, put it down! - http://www.cafepress.com/putitdown

More information about the Python-ideas mailing list