diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2024-03-25 15:32:11 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-25 15:32:11 (GMT) |
commit | 0c1a42cf9c8cd0d4534d5c1d58f118ce7c5c446e (patch) | |
tree | 929ca228612a2f48b5e7afa86101fcecb04ad29d /Misc/NEWS.d/next/C API | |
parent | 01e7405da400e8997f8964d06cc414045e144681 (diff) | |
download | cpython-0c1a42cf9c8cd0d4534d5c1d58f118ce7c5c446e.zip cpython-0c1a42cf9c8cd0d4534d5c1d58f118ce7c5c446e.tar.gz cpython-0c1a42cf9c8cd0d4534d5c1d58f118ce7c5c446e.tar.bz2 |
gh-87193: Support bytes objects with refcount > 1 in _PyBytes_Resize() (GH-117160)
Create a new bytes object and destroy the old one if it has refcount > 1.
Diffstat (limited to 'Misc/NEWS.d/next/C API')
-rw-r--r-- | Misc/NEWS.d/next/C API/2024-03-22-19-29-24.gh-issue-87193.u7O-jY.rst | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/C API/2024-03-22-19-29-24.gh-issue-87193.u7O-jY.rst b/Misc/NEWS.d/next/C API/2024-03-22-19-29-24.gh-issue-87193.u7O-jY.rst new file mode 100644 index 0000000..cb921a9 --- /dev/null +++ b/Misc/NEWS.d/next/C API/2024-03-22-19-29-24.gh-issue-87193.u7O-jY.rst @@ -0,0 +1,3 @@ +:c:func:`_PyBytes_Resize` can now be called for bytes objects with reference +count > 1, including 1-byte bytes objects. It creates a new bytes object and +destroys the old one if it has reference count > 1. |