Exception handling
Aahz
aahz at pythoncraft.com
Wed May 8 14:37:44 EDT 2002
In article <lksn52vpf0.fsf at pc150.maths.bris.ac.uk>,
Michael Hudson <mwh at python.net> wrote:
>Philip Swartzleonard <starx at pacbell.net> writes:
>> Michael Hudson || Wed 08 May 2002 03:58:31a:
>>> Järvinen Petri <jarvin24 at lehtori.cc.tut.fi> writes:
>>>>
>>>> I mean can I catch baseclass exception in my exception handler and
>>>> get all the derived classes catched aswell, like
>>>
>>> Yes. Didn't you try it? Although A should have Exception amongst
>>> it's base classes...
>>
>> Should it?
>
>Yes, but it's only "should". It's not enforced anywhere. There was
>talk of making it enforced, but I don't think that got anywhere.
I believe Guido is still talking about doing this for Python 3.0.
--
Aahz (aahz at pythoncraft.com) <*> http://www.pythoncraft.com/
See me at OSCON! I'm teaching Python for [Perl] Programmers, a fast intro
for all experienced programmers (not just Perl). Early bird ends June 10.
http://conferences.oreillynet.com/os2002/
More information about the Python-list
mailing list