[issue41784] Promote PyUnicode_AsUTF8AndSize to be available with the limited API (PEP 384)

Alex Gaynor report at bugs.python.org
Mon Sep 14 15:37:03 EDT 2020


New submission from Alex Gaynor <alex.gaynor at gmail.com>:

This function is incredibly useful for efficient interoperability between Python and other languages with UTF-8 based strings (e.g. Rust). Right now it's not possible to do interop without several copies/allocations if you're trying to build an abi3 wheel. This is tactically relevant to me here: https://github.com/PyO3/pyo3/issues/1125

This API has been stable since it was introduced in Python 3.1, so I think making it stable would be appropriate.

Inada, Benjamin suggested I should ask you for your feedback on this. I'm happy to send a pull request.

----------
components: C API
keywords: easy (C)
messages: 376896
nosy: alex, benjamin.peterson, inada.naoki
priority: normal
severity: normal
status: open
title: Promote PyUnicode_AsUTF8AndSize to be available with the limited API (PEP 384)
type: enhancement

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue41784>
_______________________________________


More information about the Python-bugs-list mailing list