Repository navigation
Undocumented 3.14 C API #135755
Description
Activity
- addeddocsDocumentation in the Doc dirDocumentation in the Doc dir
on Jun 20, 2025 For
PyFunction_GET_BUILTINS, I don't think we document any existingPyFunction_GET_*functions. I'm happy to take on documenting all those if you haven't started with it.Reacted by Petr ViktorinI'll take care of adding the
PY_*toHACLones, though the HACL ones are actually because of mismatches. I actually don't remember why we have those mismatches in the first place...- addedextension-modulesC modules in the Modules dirC modules in the Modules dirand removedextension-modulesC modules in the Modules dirC modules in the Modules dir
on Jun 20, 2025 Thank you, go ahead!
I'd prefer if the people involved in adding them are also involved in the documentation -- it's no always easy to guess the intent :)Should
Py_TPFLAGS_PREHEADER(Include/object.h) also be documented?@sergey-miryanov: Yes, though it was added in 3.12; you might want to reopen #95245 where it was added.
Now done
Reacted by Sergey Miryanov- added a commit that references this issue
on Jun 25, 2025 56 remaining items
Should
Py_TAIL_CALL_INTERPbe made private as well?Should Py_TAIL_CALL_INTERP be made private as well?
Unless there is a clear usage for it in 3rd party code, I would also suggest to make it private.
Should Py_TAIL_CALL_INTERP be made private as well?
Unless there is a clear usage for it in 3rd party code, I would also suggest to make it private.
Ok I think this should be made private then. Unfortunately, I'm not sure how to do it. Do I just add an underscore in front?
Ok I think this should be made private then. Unfortunately, I'm not sure how to do it. Do I just add an underscore in front?
Yes, just add an underscore prefix.
- added a commit that references this issue
on Sep 1, 2025 - added a commit that references this issue
on Sep 16, 2025 @Fidget-Spinner: I wrote #138981 to rename
Py_TAIL_CALL_INTERPto_Py_TAIL_CALL_INTERP.For the record, for 3.15 the same scan only found API that shouldn't be documented: #149685
Thanks @ZeroIntensity for adding the CI check in #142102!Reacted by Peter Bierma
Metadata
Metadata
Assignees
Labels
Projects
- StatusShow more project fieldsTodo
The following public C API is new in 3.14 (beta 3 & 4, relative to 3.13.0), and as of this writing it looks either:
previously: 3.13
next: 3.15
Py_INCREF_MORTAL: Include/refcount.h:251 (Use tagged pointers on the stack in the default build. #127705 (comment))MAX_SCRIPT_PATH_SIZE: Include/cpython/pystate.h:31 (PEP 768, gh-131591: Add Py_ prefix to MAX_SCRIPT_PATH_SIZE; remove unprefixed struct tag #135924)Py_MAX_SCRIPT_PATH_SIZEPyFunction_GET_BUILTINS: Include/cpython/funcobject.h:100 (added in gh-132775: Add _PyCode_GetVarCounts() #133128; assigned to @ZeroIntensity) (gh-135755: MovePyFunction_GET_BUILTINSto the private API #135938)struct _remote_debugger_support: Include/cpython/pystate.h:32 (PEP 768, gh-131591: Add Py_ prefix to MAX_SCRIPT_PATH_SIZE; remove unprefixed struct tag #135924)"
PYOS" (#135928):PYOS_LOG2_STACK_MARGIN: Include/pythonrun.hPYOS_STACK_MARGIN_BYTES: Include/pythonrun.hPYOS_STACK_MARGIN_SHIFT: Include/pythonrun.h"
SPECIAL" (#135922):SPECIAL_MAX: Include/ceval.hSPECIAL___AENTER__: Include/ceval.hSPECIAL___AEXIT__: Include/ceval.hSPECIAL___ENTER__: Include/ceval.hSPECIAL___EXIT__: Include/ceval.hHeader guards (traditionally named
Py_*_H, but a leading underscore would be better for new ones) (#135921):Py_AUDIT_H: Include/audit.hPy_CPYTHON_AUDIT_H: Include/audit.hPy_REFCOUNT_H: Include/refcount.hNew configure constants.
(IMO, if we don't want users to touch these, they should use the
_Pyprefix.If we do want users to use them, they need docs.)
Py_FFI_SUPPORT_C_COMPLEX(gh-125206: Make _Py_FFI_SUPPORT_C_COMPLEX private #135932)Py_NORMALIZE_CENTURY(gh-120713: Make _Py_NORMALIZE_CENTURY private #135933)Py_REMOTE_DEBUG(gh-131591: Document Py_REMOTE_DEBUG #135929)HACL_CAN_COMPILE_SIMD128(gh-135755: rename undocumentedHACL_CAN_COMPILE_SIMD{128,256}macros #135847)HACL_CAN_COMPILE_SIMD256(gh-135755: rename undocumentedHACL_CAN_COMPILE_SIMD{128,256}macros #135847)New
HAVEconfigure constants -- a lost cause:HAVE_BACKTRACEHAVE_DECL_UT_NAMESIZEHAVE_DLADDRHAVE_DLADDR1HAVE_EXECINFO_HHAVE_GETLOGIN_RHAVE_LINK_HHAVE_LINUX_NETFILTER_IPV4_HHAVE_LINUX_SCHED_HHAVE_PTHREAD_GETATTR_NPHAVE_PTHREAD_GETNAME_NPHAVE_PTHREAD_SETNAME_NPHAVE_SYS_PIDFD_H3HAVE_TTYNAME_RHAVE_USABLE_WCHAR_THAVE_UT_NAMESIZENew
CO_flags (documented in inspect; Sphinx sees none of these as C macros): (#135980)CO_HAS_DOCSTRING: Include/cpython/code.h:115CO_METHOD: Include/cpython/code.h:115Linked PRs
PyFunction_GET*macros #135762HACL_CAN_COMPILE_SIMD{128,256}macros #135847PyFunction_GET*macros (GH-135762) #135916PyFunction_GET*macros (GH-135762) #135917PyFunction_GET_BUILTINSmacro #135934PyFunction_GET_BUILTINSto the private API #135938HACL_CAN_COMPILE_SIMD{128,256}macros (GH-135847) #136045