[Python-3000] Pre-peps on raise and except changes

Collin Winter collinw at gmail.com
Sat Jan 27 03:41:18 CET 2007


On 1/26/07, Greg Ewing <greg.ewing at canterbury.ac.nz> wrote:
> Collin Winter wrote:
> > On 1/26/07, Greg Ewing <greg.ewing at canterbury.ac.nz> wrote:
>> >> That wording doesn't seem to cover the case where
> >> E is an instance of a subclass of BaseException.
> >
> >>>> class A: pass
> >>>> class B(A): pass
> >>>> isinstance(B(), A)
>> Technically I suppose it's right, but it doesn't sound
> very clear to me.
>> Maybe something like
>> E may be an exception class or an instance of an
> exception class. Valid exception classes are
> BaseException and its subclasses.

I'll use that.
Thanks,
Collin Winter


More information about the Python-3000 mailing list

AltStyle によって変換されたページ (->オリジナル) /