]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-125196: Use PyUnicodeWriter for repr(structseq) (#125219)
authorVictor Stinner <vstinner@python.org>
Wed, 9 Oct 2024 22:04:50 +0000 (00:04 +0200)
committerGitHub <noreply@github.com>
Wed, 9 Oct 2024 22:04:50 +0000 (22:04 +0000)
commit1877543d03d323d581b5fc0f19eff501926ba151
treed6cca815d46047e22f343bb92bd732d22bf42e0f
parentee3167b9787bf9424d5637a224233de775450231
gh-125196: Use PyUnicodeWriter for repr(structseq) (#125219)

Replace the private _PyUnicodeWriter with the public PyUnicodeWriter.

* Avoid temporary PyUnicode_DecodeUTF8(): call
  PyUnicodeWriter_WriteUTF8() instead.
* Avoid temporary PyObject_Repr(): call PyUnicodeWriter_WriteRepr()
  instead.
Objects/structseq.c