R: [Python-Dev] Deprecating string exceptions

Guido van Rossum guido@python.org
Thu, 28 Mar 2002 09:43:55 -0500


> Which, to my mind, is sufficient to justify the rule.

And also to mine.  (Barry, take note for the PEP. :-)

> Hmm. If the rule were (eventually) strictly enforced,
> could we get the C++-style "stack allocated object
> whose destructor releases the resource" trick working?

(a) I'm not sure I like to make that semantics official, since it's
    hard to implement e.g. in Jython.

(b) I'm having another dense day.  How would requiring exceptions to
    inherit from Exception make this easier?

> (Which would allow killing off the recurrent "with" /
> "using" thread.)

In c.l.py?  I'm not aware of it.

--Guido van Rossum (home page: http://www.python.org/~guido/)