Skip to content

Commit 6889905

Browse files
committed
Classify a few ambiguous functions
PyMarshal_*, PyMember_{Get,Set}One, PyThreadState_DeleteCurrent, Py_GetArgcArgv are not declared with Py_LIMITED_API, so they're not part of the limited API. They stay in the stable ABI, though. PyInterpreterState_GetID part of limited API and stable ABI. PyOS_ReadlineFunctionPointer is removed from the stable ABI records, as functions expecting FILE* are not part of the ABI. Ssee bpo-43868.
1 parent 9dac21c commit 6889905

File tree

2 files changed

+9
-12
lines changed

2 files changed

+9
-12
lines changed

Doc/data/stable_abi.dat

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -318,6 +318,7 @@ PyInterpreterState_Clear
318318
PyInterpreterState_Delete
319319
PyInterpreterState_Get
320320
PyInterpreterState_GetDict
321+
PyInterpreterState_GetID
321322
PyInterpreterState_New
322323
PyIter_Check
323324
PyIter_Next
@@ -453,7 +454,6 @@ PyOS_CheckStack
453454
PyOS_FSPath
454455
PyOS_InputHook
455456
PyOS_InterruptOccurred
456-
PyOS_ReadlineFunctionPointer
457457
PyOS_double_to_string
458458
PyOS_getsig
459459
PyOS_mystricmp
@@ -589,7 +589,6 @@ PySys_WriteStdout
589589
PyThreadState
590590
PyThreadState_Clear
591591
PyThreadState_Delete
592-
PyThreadState_DeleteCurrent
593592
PyThreadState_Get
594593
PyThreadState_GetDict
595594
PyThreadState_GetFrame
@@ -793,7 +792,6 @@ Py_FinalizeEx
793792
Py_FrozenMain
794793
Py_GenericAlias
795794
Py_GenericAliasType
796-
Py_GetArgcArgv
797795
Py_GetBuildInfo
798796
Py_GetCompiler
799797
Py_GetCopyright

Misc/stable_abi.txt

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1010,8 +1010,6 @@ data PyOS_InputHook
10101010
added 3.2
10111011
function PyOS_InterruptOccurred
10121012
added 3.2
1013-
data PyOS_ReadlineFunctionPointer
1014-
added 3.2
10151013
function PyOS_double_to_string
10161014
added 3.2
10171015
function PyOS_getsig
@@ -1248,7 +1246,7 @@ function PyThreadState_Delete
12481246
added 3.2
12491247
function PyThreadState_DeleteCurrent
12501248
added 3.2
1251-
# See also: https://bugs.python.org/issue37878
1249+
abi_only
12521250
function PyThreadState_Get
12531251
added 3.2
12541252
function PyThreadState_GetDict
@@ -1676,19 +1674,20 @@ const METH_COEXIST
16761674
# METH_STACKLESS is undocumented
16771675
# METH_FASTCALL is not part of limited API.
16781676

1679-
# PEP 384 doesn't exclude PyMarshal_* in general, only functions
1680-
# that take FILE*.
1677+
# The following are defined in private headers, but historically
1678+
# they were exported as part of the stable ABI.
16811679
function PyMarshal_ReadObjectFromString
16821680
added 3.2
1681+
abi_only
16831682
function PyMarshal_WriteObjectToString
16841683
added 3.2
1685-
1684+
abi_only
16861685
function PyMember_GetOne
1687-
# Undocumented, which doesn't matter according to PEP 384
16881686
added 3.2
1687+
abi_only
16891688
function PyMember_SetOne
1690-
# Undocumented, which doesn't matter according to PEP 384
16911689
added 3.2
1690+
abi_only
16921691

16931692
# TLS api is deprecated; superseded by TSS API
16941693

@@ -1979,7 +1978,6 @@ function PySlice_Unpack
19791978

19801979
function PyInterpreterState_GetID
19811980
added 3.7
1982-
abi_only
19831981
function PyThread_tss_alloc
19841982
added 3.7
19851983
function PyThread_tss_create
@@ -2062,6 +2060,7 @@ function PyObject_GC_IsTracked
20622060

20632061
function Py_GetArgcArgv
20642062
added 3.10
2063+
abi_only
20652064
function PyIter_Send
20662065
added 3.10
20672066
function PyUnicode_AsUTF8AndSize

0 commit comments

Comments
 (0)