Skip to content

C API: Remove private C API functions (move them to the internal C API) #106320

@vstinner

Description

@vstinner

Over the years, we accumulated many private functions as part of the public C API header files. I propose to remove them: move them to the internal C API.

If many C extensions are affected by these removals, it's a sign that we should consider promoted used private functions as public functions: provide a better API, add error handling, write documentation, write tests.


Summary: My plan to clarify private vs public functions in Python 3.13


Linked PRs

Activity

added 3 commits that reference this issue on Jul 1, 2023
vstinner

vstinner commented on Jul 1, 2023

@vstinner
MemberAuthor

See also issue #106316: remove pytime.h header file (_PyTime functions).

vstinner

vstinner commented on Jul 1, 2023

@vstinner
MemberAuthor

See also issue #106084: C API: Remove private functions from abstract.h.

vstinner

vstinner commented on Jul 1, 2023

@vstinner
MemberAuthor

See also commit 0b51463:

Remove the following private functions of the C API:

* _PyCodecInfo_GetIncrementalDecoder()
* _PyCodecInfo_GetIncrementalEncoder()
* _PyCodec_DecodeText()
* _PyCodec_EncodeText()
* _PyCodec_Forget()
* _PyCodec_Lookup()
* _PyCodec_LookupTextEncoding()
added 4 commits that reference this issue on Jul 1, 2023
18b1fde
added 2 commits that reference this issue on Jul 2, 2023

404 remaining items

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      C API: Remove private C API functions (move them to the internal C API) · Issue #106320 · python/cpython