summaryrefslogtreecommitdiffstats
path: root/Misc
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2008-08-26 16:46:47 (GMT)
committerBenjamin Peterson <benjamin@python.org>2008-08-26 16:46:47 (GMT)
commitc15a07333e712e682036d9ecb7230d25ccb1a85f (patch)
tree52eee04b10bc95047d25c9dd6b82ec9e48efeb97 /Misc
parenta786b026c9992cee195b7a550bab2c70c50f874f (diff)
downloadcpython-c15a07333e712e682036d9ecb7230d25ccb1a85f.zip
cpython-c15a07333e712e682036d9ecb7230d25ccb1a85f.tar.gz
cpython-c15a07333e712e682036d9ecb7230d25ccb1a85f.tar.bz2
make bytes(o) respect __bytes__ #2415
This adds two new C-API functions: PyObject_Bytes and PyBytes_FromObject. Reviewer: Barry
Diffstat (limited to 'Misc')
-rw-r--r--Misc/NEWS7
1 files changed, 7 insertions, 0 deletions
diff --git a/Misc/NEWS b/Misc/NEWS
index 8594c99..d779132 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -27,6 +27,13 @@ Core and Builtins
- Issue #3650: Fixed a reference leak in bytes.split('x').
+- bytes(o) now tries to use o.__bytes__() before using fallbacks.
+
+C API
+-----
+
+- PyObject_Bytes and PyBytes_FromObject were added.
+
Library
-------