[Python-ideas] except expression

Chris Angelico rosuav at gmail.com
Tue Feb 18 16:51:20 CET 2014


On Wed, Feb 19, 2014 at 2:41 AM, Alexander Belopolsky
<alexander.belopolsky at gmail.com> wrote:
> I would not mind
>
>  x = 1/f(y) except 0
>
> not catching a TypeError that may come from f(y) in most cases.

But should it catch a KeyError from inside f(y), based on the
translation of d.get()?

ChrisA


More information about the Python-ideas mailing list