[Python-Dev] PEP 205 comments

Guido van Rossum guido@python.org
Mon, 15 Jan 2001 11:17:07 -0500

I'll leave most of this to Fred, but I'll reply to two items (Fred can
add these replies to the PEP):

> Again on proxies, there is no discussion or documentation of the
> ReferenceError. Why is it a RuntimeError? LookupError, ValueError, and
> AttributeError seem to be just as fine or better.

RuntimeError was my suggestion.  The error doesn't really qualify as a
LookupError in my view (there's no key that could be valid or invalid)
and ValueError seems too general (that's typically used for
out-of-range arguments and unparseable strings and the like).  Do you
have a reason why RuntimeError is inappropriate?

> On to the type type extensions: Should there be a type flag indicating
> presence of tp_weaklistoffset? It appears that the type structure had
> tp_xxx7 for a long time, so likely all in-use binary modules have
> that field set to zero. Is that sufficient?

Yes, that should be sufficient.  (I'm also going to clain tp_xxx7 for
the rich comparison function slot, but either patch can be modified to
use tp_xxx8 instead.)  Maybe it's time to add a bunch of new spares?

> Thanks for reading all of this message,

You're welcome.

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