[Python-bugs-list] [ python-Bugs-591135 ] Mixin broken for new-style classes
noreply@sourceforge.net
noreply@sourceforge.net
Sun, 18 Aug 2002 15:58:25 -0700
Bugs item #591135, was opened at 2002-08-05 10:31
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=591135&group_id=5470
Category: None
Group: None
>Status: Closed
>Resolution: Duplicate
Priority: 5
Submitted By: Joost Jacob (jjacob)
Assigned to: Nobody/Anonymous (nobody)
Summary: Mixin broken for new-style classes
Initial Comment:
In article:
http://www.linuxjournal.com/article.php?sid=4540
Chuck Esterbrook mentions an elegant technique
called 'Mixin'.
Assigning to __bases__ is useful if you want to add
ancestors without changing the object's source code.
It does not work with new-style classes because the
.__bases__ attribute is now read-only.
This is also mentioned on
http://www.python.org/2.2.1/bugs.html
at the bottom but I could not find a bug-report here at
SF.
----------------------------------------------------------------------
>Comment By: Raymond Hettinger (rhettinger)
Date: 2002-08-18 17:58
Message:
Logged In: YES
user_id=80475
Merged this bug report into SF bug 593154.
Closing this one so the discussion can all be in one place.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=591135&group_id=5470