GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — C API: No longer export internal C API functions · Issue #107211 · python/cpython

C API: No longer export internal C API functions #107211

New issue
Copy link
New issue
Copy link
Closed
Closed
C API: No longer export internal C API functions#107211
Copy link
Assignees
vstinner
Labels
topic-C-APItype-featureA feature request or enhancementA feature request or enhancement

Description

@vstinner
vstinner
opened on Jul 25, 2023
Issue body actions

Many internal C API functions are exported with PyAPI_FUNC() and internal variables are exported with PyAPI_DATA(), whereas these APIs should not be used outside Python internals.

I propose to replace PyAPI_FUNC() and PyAPI_DATA() with extern on symbols which are not used by stdlib shared extensions.

The exception should be to export, not the default. For example, the _PyObject_DebugMallocStats() function is exported by the 3rd party guppy3 project.

See also issue #106320: C API: Remove private C API functions (move them to the internal C API).

Linked PRs

  • gh-107211: Rename PySymtable_Lookup() to _PySymtable_Lookup() #107212
  • gh-107211: No longer export internal functions (1) #107213
  • gh-107211: No longer export internal functions (2) #107214
  • gh-107211: No longer export internal functions (3) #107215
  • gh-107211: No longer export internal functions (4) #107217
  • gh-107211: No longer export internal variables #107218
  • gh-107211: Fix select extension build on Solaris #108012
  • gh-107211: No longer export pycore_strhex.h functions #108229
  • gh-107211: No longer export PyTime internal functions #108422
  • gh-107211: No longer export internal functions (5) #108423
  • gh-107211: No longer export internal functions (6) #108424
  • gh-107211: No longer export internal functions (7) #108425
  • gh-107211: Fix test_peg_generator #108435
  • gh-107211: No longer export internal _PyLong_FromUid() #109037

Activity

Next
  1. vstinner
    added
    type-featureA feature request or enhancementA feature request or enhancement
    topic-C-API
    on Jul 25, 2023
  2. vstinner
    added 13 commits that reference this issue on Jul 25, 2023

    pythongh-107211: Rename PySymtable_Lookup() to _PySymtable_Lookup()

    3ba33ba

    pythongh-107211: No longer export internal functions (1)

    f126410

    pythongh-107211: No longer export internal functions (1)

    f17f73b

    pythongh-107211: No longer export internal functions (2)

    601d099

    pythongh-107211: No longer export internal functions (3)

    a906376

    pythongh-107211: No longer export internal functions (1)

    8b7c505

    pythongh-107211: No longer export internal functions (1)

    f045079

    gh-107211: Rename PySymtable_Lookup() to _PySymtable_Lookup() (#107212)

    2e07449

    pythongh-107211: No longer export internal functions (2)

    85d3727

    pythongh-107211: No longer export internal functions (1)

    64e11f6

    pythongh-107211: No longer export internal functions (3)

    0a9388d

    pythongh-107211: No longer export internal functions (3)

    1894882

    gh-107211: No longer export internal functions (1) (#107213)

    11306a9
  3. 37 remaining items

  4. vstinner
    added 10 commits that reference this issue on Aug 24, 2023

    pythongh-107211: No longer export internal functions (7)

    d0152f8

    pythongh-107211: No longer export internal functions (7)

    25d79fc

    pythongh-107211: No longer export internal functions (5)

    307c3fe

    gh-107211: No longer export PyTime internal functions (#108422)

    3f7e93b

    gh-107211: No longer export internal functions (6) (#108424)

    ea871c9

    pythongh-107211: No longer export internal functions (5)

    1c53af2

    gh-107211: No longer export internal functions (7) (#108425)

    f1ae706

    gh-107211: No longer export internal functions (5) (#108423)

    b780882

    pythongh-107211: Fix test_peg_generator

    312d377

    gh-107211: Fix test_peg_generator (#108435)

    fa6933e
  5. vstinner
    closed this as completedon Aug 26, 2023
  6. vstinner commented on Aug 26, 2023

    @vstinner
    vstinner
    on Aug 26, 2023
    MemberAuthor
    More actions

    Ok, now we should be good.

  7. vstinner
    added 3 commits that reference this issue on Sep 6, 2023

    pythongh-107211: No longer export internal _PyLong_FromUid()

    d7529e1

    pythongh-107211: No longer export internal _PyLong_FromUid()

    b74fe2a

    gh-107211: No longer export internal _PyLong_FromUid() (#109037)

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

Metadata

Metadata

Assignees

  • @vstinner
    vstinner

Labels

topic-C-APItype-featureA feature request or enhancementA feature request or enhancement

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402503 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.