gh-141004: Document PyBytes_Repr and PyBytes_DecodeEscape#141407
gh-141004: Document PyBytes_Repr and PyBytes_DecodeEscape#141407ZeroIntensity merged 6 commits intopython:mainfrom
PyBytes_Repr and PyBytes_DecodeEscape#141407Conversation
Doc/c-api/bytes.rst
Outdated
| Get the string representation of *bytes*. This function is used to | ||
| implement :meth:`!bytes.__repr__` in Python. |
There was a problem hiding this comment.
| Get the string representation of *bytes*. This function is used to | |
| implement :meth:`!bytes.__repr__` in Python. | |
| Get the string representation of *bytes*. | |
| *bytes* must be a bytes object. | |
| This function is used to implement :meth:`!bytes.__repr__` in Python. |
There was a problem hiding this comment.
Same remark as the other PR, this reads as "segfault if this isn't a bytes object".
There was a problem hiding this comment.
In this case, it will lead to undefined behaviour.
There was a problem hiding this comment.
Yuck! I think we should have a more explicit note then. That definitely surprised me.
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
|
Thanks @ZeroIntensity for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13, 3.14. |
|
Sorry, @ZeroIntensity, I could not cleanly backport this to |
|
Sorry, @ZeroIntensity, I could not cleanly backport this to |
|
GH-141440 is a backport of this pull request to the 3.14 branch. |
…ythonGH-141407) Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com> (cherry picked from commit 37e2762)
…cape` (pythonGH-141407) (cherry picked from commit 37e2762) Co-authored-by: Peter Bierma <zintensitydev@gmail.com> Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
|
GH-141441 is a backport of this pull request to the 3.13 branch. |
…ythonGH-141407) Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com> (cherry picked from commit 37e2762)
…cape` (pythonGH-141407) (cherry picked from commit 37e2762) Co-authored-by: Peter Bierma <zintensitydev@gmail.com> Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
…ythonGH-141407) Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
📚 Documentation preview 📚: https://cpython-previews--141407.org.readthedocs.build/en/141407/c-api/bytes.html#c.PyBytes_Repr