A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2017-November/150667.html below:

[Python-Dev] Python initialization and embedded Python

[Python-Dev] Python initialization and embedded Python [Python-Dev] Python initialization and embedded PythonEric Snow ericsnowcurrently at gmail.com
Mon Nov 20 16:35:58 EST 2017
On Mon, Nov 20, 2017 at 8:43 AM, Victor Stinner
<victor.stinner at gmail.com> wrote:
> 2017-11-20 16:31 GMT+01:00 Eric Snow <ericsnowcurrently at gmail.com>:
>> That Py_DecodeLocale() can use PyMem_RawMalloc() pre-init is an implementation detail.
>
> Py_DecodeLocale() uses PyMem_RawMalloc(), and so its result must be
> freed by PyMem_RawFree(). It's part the documentation.

Ah, I'd missed that.  Thanks for pointing it out.

>
> I'm not sure that I understood correctly. Do you agree to move "PyMem"
> globals back to Objects/obmalloc.c? (to allow to call
> PyMem_RawMalloc() before Py_Initialize())

I'm okay with that if we can't find another way.  However, shouldn't
we be able to statically initialize the raw allocator in _PyRuntime,
much as we were doing before in obmalloc.c?  I have a rough PR up:

    https://github.com/python/cpython/pull/4481

Also, I opened https://bugs.python.org/issue32096 for the regression.
Thanks for bringing it up.

-eric
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4