New submission from STINNER Victor:

I would like to deprecate PyUnicode_AsUnicode(), see the issue #22271 for the 
rationale (hint: memory footprint).

To deprecate PyUnicode_AsUnicode(), we should stop using it internally.

The attached patch is a work-in-progress patch, untested on Windows (only 
tested on Linux). It gives an idea of how many files should be modified.

TODO:

* Modify posixmodule.c: I don't understand how the Argument Clinic generates 
the call to PyUnicode_AsUnicode() when the parameter type is declared as 
"unicode". What is the "unicode" type? Where is the code generating the call to 
PyUnicode_AsUnicode()?

* Modify a few other files.

----------
files: wchar.patch
keywords: patch
messages: 226247
nosy: haypo, loewis
priority: normal
severity: normal
status: open
title: Use PyUnicode_AsWideCharString() instead of PyUnicode_AsUnicode()
type: enhancement
versions: Python 3.5
Added file: http://bugs.python.org/file36522/wchar.patch

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue22324>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to