Antonio Cuni
315fc52db1
bpo-42528: Improve the docs of most Py*_Check{,Exact} API calls (GH-23602)
...
I think that none of these API calls can fail, but only few of them are
documented as such. Add the sentence "This function always succeeds" (which is
the same already used e.g. by PyNumber_Check) to all of them.
2021-01-06 12:38:26 +01:00
Serhiy Storchaka
686c203cd4
bpo-42423: Accept single base class in PyType_FromModuleAndSpec() (GH-23441)
2020-11-22 13:25:02 +02:00
Serhiy Storchaka
1db76394ea
bpo-42412: Fix possible leaks and check arguments in PyType_FromModuleAndSpec() (GH-23410)
...
* There were leaks if Py_tp_bases is used more than once or if some call is
failed before setting tp_bases.
* There was a crash if the bases argument or the Py_tp_bases slot is not a tuple.
* The documentation was not accurate.
2020-11-21 12:02:53 +02:00
Hai Shi
2b39da4997
bpo-41832: Restore note about NULL in PyType_Slot.pfunc (GH-23243)
2020-11-14 13:03:42 +01:00
Hai Shi
a13b26cac1
bpo-41073: PyType_GetSlot() can now accept static types. (GH-21931)
...
PyType_GetSlot() can now accept static types.
Co-Authored-By: Petr Viktorin <encukou@gmail.com >
Automerge-Triggered-By: GH:encukou
2020-11-10 12:53:46 -08:00
Hai Shi
88c2cfd9ff
bpo-41832: PyType_FromModuleAndSpec() now accepts NULL tp_doc (GH-23123)
2020-11-06 17:04:47 +01:00
Benjamin Peterson
700fa1b836
Note the buffer slots can be set with PyType_Spec with the unlimited API. (GH-22031)
...
Follow up to f7c4e23642 .
2020-09-01 20:36:42 -05:00
Petr Viktorin
d9a966ae08
bpo-38787: Clarify docs for PyType_GetModule and warn against common mistake (GH-20215)
2020-08-27 15:36:48 +02:00
Hai Shi
86d69444e7
bpo-40584: Update PyType_FromModuleAndSpec() to process tp_vectorcall_offset (GH-20026)
2020-05-11 23:38:55 +02:00
Petr Viktorin
e1becf46b4
bpo-38787: C API for module state access from extension methods (PEP 573) (GH-19936)
...
Module C state is now accessible from C-defined heap type methods (PEP 573).
Patch by Marcel Plch and Petr Viktorin.
Co-authored-by: Marcel Plch <mplch@redhat.com >
Co-authored-by: Victor Stinner <vstinner@python.org >
2020-05-07 15:39:59 +02:00
Victor Stinner
509dd90f46
bpo-39542: Convert PyType_Check() to static inline function (GH-18364)
...
Convert PyType_HasFeature(), PyType_Check() and PyType_CheckExact()
macros to static inline functions.
2020-02-05 14:24:17 +01:00
Jeroen Demeyer
9a13a388f2
bpo-36974: expand call protocol documentation (GH-13844)
...
CC @encukou
I'm also adding Petr Viktorin as contributor for vectorcall in the "what's new" section.
https://bugs.python.org/issue36974
Automerge-Triggered-By: @encukou
Automerge-Triggered-By: @encukou
2019-11-12 05:08:00 -08:00
Serhiy Storchaka
e835b31d2b
bpo-38600: NULL -> `NULL`. (GH-17001)
...
Also fix some other formatting.
2019-10-30 21:37:16 +02:00
Serhiy Storchaka
25fc088607
bpo-38600: Change the mark up of NULL in the C API documentation. (GH-16950)
...
Replace all *NULL* with ``NULL``.
2019-10-30 12:03:20 +02:00
Ammar Askar
5faff977ad
bpo-38206: Clarify tp_dealloc requirements for heap allocated types. (GH-16248)
...
As mentioned in the bpo ticket, this mistake came up on two reviews:
- https://github.com/python/cpython/pull/16127#pullrequestreview-288312751
- https://github.com/python/cpython/pull/16071#pullrequestreview-287819525
Would be nice to have it documented in a more permanent place than 3.8's whatsnew entry.
https://bugs.python.org/issue38206
Automerge-Triggered-By: @encukou
2019-09-27 04:11:27 -07:00
Petr Viktorin
468f8a6ee0
bpo-38140: Document offsets in PyMemberDef (GH-16354)
...
bpo-38140: Document offsets in PyMemberDef
Co-Authored-By: Ammar Askar <ammar_askar@hotmail.com >
2019-09-25 13:06:16 +02:00
Eddie Elizondo
3368f3c6ae
bpo-38140: Make dict and weakref offsets opaque for C heap types ( #16076 )
...
* Make dict and weakref offsets opaque for C heap types
* Add news
2019-09-19 17:29:05 +01:00
t k
8b31a11a69
bpo38158: Removing nonexistant member "doc" from PyType_Spec documentation (GH-16142)
2019-09-15 07:50:05 +01:00
Petr Viktorin
f1e17e9f97
bpo-34626: Document creating heap types from the C-API (GH-9154)
...
bpo-34626: Document creating heap types from the C-API
Add missing descriptions of PEP384's PyType_Spec and PyType_Slot,
along with some introductory prose.
2019-05-24 11:19:42 +02:00
Stéphane Wirtel
cbb6484573
Doc: Replace the deprecated highlightlang directive by highlight. ( #13377 )
...
highlightlang is deprecated since April 2018 in Sphinx.
See https://github.com/sphinx-doc/sphinx/pull/4845
2019-05-17 15:25:34 +05:30
Eddie Elizondo
9fbcfc08e5
bpo-16086: Fix PyType_GetFlags() documentation (GH-10758)
...
PyType_GetFlags() return type is unsigned long, not long.
2018-11-29 10:11:36 +01:00
Georg Brandl
f6d6dc2e36
Clean up the docs of PyObject_IsSubclass and PyObject_IsInstance, and mention that they call the PEP 3119 methods.
2014-10-06 14:38:53 +02:00
Georg Brandl
a920b6d762
Closes #22507 : document that PyType_IsSubtype does not call __subclasscheck__.
2014-10-06 14:15:06 +02:00
Nick Coghlan
aa029dad50
Tweaks to What's New and some referenced docs
2014-02-09 10:10:24 +10:00
Martin v. Löwis
ca7b04644c
Issue #17162 : Add PyType_GetSlot.
2014-02-04 09:33:05 +01:00