New-style exceptions?

Raymond Hettinger python at rcn.com
Sun Mar 31 20:20:52 EST 2002


"Aahz" <aahz at pythoncraft.com> wrote in message
> Magnus Lie Hetland <mlh at vier.idi.ntnu.no> wrote:
> >
> >Is there a reason why new-style objects can't be used in the raise
> >statement?
>
> Because that's the way it currently works.  Inherit from Exception and
> Bob's your uncle.

Is there a reason why Exception can't be defined to inherit from 'object' so
that Uncle Bob does the right thing?


Raymond Hettinger, CPA






More information about the Python-list mailing list