[Python-Dev] Type/class differences (Re: Sets: elt in dict, lst.include)

Greg Ewing greg@cosc.canterbury.ac.nz
Fri, 02 Feb 2001 11:45:02 +1300 (NZDT)


Tim Peters <tim.one@home.com>:

> The old type/class split:  list is a type, and types spell their "method
> tables" in ways that have little in common with how classes do it.

Maybe as a first step towards type/class unification one
day, we could add __xxx__ attributes to all the builtin
types, and start to think of the method table as the
definitive source of all methods, with the tp_xxx slots
being a sort of cache for the most commonly used ones.

Greg Ewing, Computer Science Dept, +--------------------------------------+
University of Canterbury,	   | A citizen of NewZealandCorp, a	  |
Christchurch, New Zealand	   | wholly-owned subsidiary of USA Inc.  |
greg@cosc.canterbury.ac.nz	   +--------------------------------------+