Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[C API] Make _PyTuple_FromArray() function public #111489

Closed
Labels
@vstinner

Description

@vstinner

I dislikePyList_New() +PyList_SET_ITEM() API since the list is immediately tracked by the GC and so callinggc.get_objects() can expose an invalid list object (ex: callingrepr(list) can crash). See:

The internalPyObject * _PyTuple_FromArray(PyObject *const *src, Py_ssize_t n) function should be made public.

cc@erlend-aasland

UPDATE: I updated the issue to request promoting_PyTuple_FromArray() instead of_PyList_FromArraySteal().

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp