[Python-Dev] Breaking calls to object.init/new (original) (raw)
Guido van Rossum guido at python.org
Thu Mar 22 05:42:34 CET 2007
- Previous message: [Python-Dev] Breaking calls to object.__init__/__new__
- Next message: [Python-Dev] Breaking calls to object.__init__/__new__
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 3/21/07, Terry Reedy <tjreedy at udel.edu> wrote:
It seems to me that to get the exact behavior one wants at the apex of a diamond structure, one should subclass object and override .init with a function that does not call object.init and use that subclass as the apex instead of object itself. Wouldn't this mask the behavior of object.init and whatever changes decided on?
Yup, that's what I recommended for Aahz.
(But having said that, I have no opiniou on what the default should be for those who don't do this.)
I do now -- for the single inheritance case, refusing extra args makes the most sense too, so that sohuld be the default in 3.0. With a Py3k warning in 2.6.
-- --Guido van Rossum (home page: http://www.python.org/~guido/)
- Previous message: [Python-Dev] Breaking calls to object.__init__/__new__
- Next message: [Python-Dev] Breaking calls to object.__init__/__new__
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]