summaryrefslogtreecommitdiffstats
path: root/Misc
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2003-02-12 03:58:38 (GMT)
committerGuido van Rossum <guido@python.org>2003-02-12 03:58:38 (GMT)
commita89d10edc94b3c1c62a6920d4b6b8219675f36da (patch)
tree4b614ef1cd6bc73f36397b8e3320f0f70f412ee7 /Misc
parente5b130bcdb491b7d4af7cd4c9cf82ebf6ba5fc63 (diff)
downloadcpython-a89d10edc94b3c1c62a6920d4b6b8219675f36da.zip
cpython-a89d10edc94b3c1c62a6920d4b6b8219675f36da.tar.gz
cpython-a89d10edc94b3c1c62a6920d4b6b8219675f36da.tar.bz2
Implement another useful feature for proxies: in super(X, x), x may
now be a proxy for an X instance, as long as issubclass(x.__class__, X).
Diffstat (limited to 'Misc')
-rw-r--r--Misc/NEWS3
1 files changed, 3 insertions, 0 deletions
diff --git a/Misc/NEWS b/Misc/NEWS
index d88f753..11521c6 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -12,6 +12,9 @@ What's New in Python 2.3 alpha 2?
Core and builtins
-----------------
+- super(X, x): x may now be a proxy for an X instance, i.e.
+ issubclass(x.__class__, X) but not issubclass(type(x), X).
+
- isinstance(x, X): if X is a new-style class, this is now equivalent
to issubclass(type(x), X) or issubclass(x.__class__, X). Previously
only type(x) was tested. (For classic classes this was already the