summaryrefslogtreecommitdiffstats
path: root/Doc/data/refcounts.dat
Commit message (Collapse)AuthorAgeFilesLines
* [3.12] gh-102468: Document `PyCFunction_New*` and `PyCMethod_New` ↵Miss Islington (bot)2024-01-171-0/+15
| | | | | | | | | (GH-112557) (GH-114119) gh-102468: Document `PyCFunction_New*` and `PyCMethod_New` (GH-112557) (cherry picked from commit a482bc67ee786e60937a547776fcf9528810e1ce) Co-authored-by: AN Long <aisk@users.noreply.github.com> Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* [3.12] gh-113696: Docs: Annotate PyObject_CallOneArg and PyObject_CallNoArgs ↵Miss Islington (bot)2024-01-051-0/+7
| | | | | | | as returning a strong reference (GH-113697) (#113698) (cherry picked from commit 1ae7ceba29771baf8f2e8d2d4c50a0355cb6b5c8) Co-authored-by: Jamie Phan <jamie@ordinarylab.dev>
* gh-101578: Amend exception docs (#102057)Erlend E. Aasland2023-02-211-0/+2
| | | Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
* gh-101578: Amend PyErr_{Set,Get}RaisedException docs (#101962)Erlend E. Aasland2023-02-191-0/+3
| | | Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
* bpo-43327: Fix the docs for PyImport_ImportFrozenModuleObject() (#24659)Zackery Spytz2022-11-271-2/+2
| | | | | | The docs stated that PyImport_ImportFrozenModuleObject() returns a new reference, but it actually returns an int. Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
* GH-93503: Add thread-specific APIs to set profiling and tracing functions in ↵Pablo Galindo Salgado2022-08-241-0/+8
| | | | | | | | | | | | | | | | | the C-API (#93504) * gh-93503: Add APIs to set profiling and tracing functions in all threads in the C-API * Use a separate API * Fix NEWS entry * Add locks around the loop * Document ignoring exceptions * Use the new APIs in the sys module * Update docs
* bpo-45123: PyAiter_Check and PyObject_GetAiter fix & rename. (GH-28194)Yury Selivanov2021-09-071-4/+4
| | | | | | | | Fix PyAiter_Check to only check for the `__anext__` presense (not for `__aiter__`). Rename `PyAiter_Check()` to `PyAIter_Check()`, `PyObject_GetAiter()` -> `PyObject_GetAIter()`. Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
* bpo-42035: Add PyType_GetQualName() to get a type's qualified name. (GH-27551)Hai Shi2021-08-171-0/+3
|
* bpo-41103: Resurrect the old buffer protocol. (GH-27437)Inada Naoki2021-07-291-0/+18
| | | | | Revert "bpo-41103: Remove old buffer protocol support (#21117)" This reverts commit 6f8a6ee59cb7f99f68df8ee9c3e8c8cf19af3eed.
* bpo-42035: Add a PyType_GetName() to get type's short name. (GH-23903)Hai Shi2021-07-291-0/+3
|
* bpo-40939: Remove documentation for `PyParser_*` & add porting notes (GH-26855)Petr Viktorin2021-06-241-26/+0
| | | | | | I tried to be relatively thorough and give lots of links. One reason is that this wasn't deprecated very long; also it seems people running into this tend to not be familiar with similar APIs. Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
* bpo-44029: Remove Py_UNICODE APIs (GH-25881)Inada Naoki2021-05-071-84/+0
| | | | | | | | | | | | Remove deprecated `Py_UNICODE` APIs: `PyUnicode_Encode`, `PyUnicode_EncodeUTF7`, `PyUnicode_EncodeUTF8`, `PyUnicode_EncodeUTF16`, `PyUnicode_EncodeUTF32`, `PyUnicode_EncodeLatin1`, `PyUnicode_EncodeMBCS`, `PyUnicode_EncodeDecimal`, `PyUnicode_EncodeRawUnicodeEscape`, `PyUnicode_EncodeCharmap`, `PyUnicode_EncodeUnicodeEscape`, `PyUnicode_TransformDecimalToASCII`, `PyUnicode_TranslateCharmap`, `PyUnicodeEncodeError_Create`, `PyUnicodeTranslateError_Create`. See :pep:`393` and :pep:`624` for reference.
* bpo-31861: Complete the C-API docs for PyObject_GetAiter and PyAiter_Check ↵Pablo Galindo2021-03-231-0/+6
| | | | (GH-25004)
* bpo-42294: Add borrowed/strong reference to doc glossary (GH-23206)Victor Stinner2020-11-091-0/+6
| | | | | | Add "borrowed reference" and "strong reference" to the documentation glossary. Enhance also Py_INCREF() and Py_NewRef() documentation.
* Delete PyGen_Send (#22663)Vladimir Matveev2020-10-121-5/+0
|
* bpo-41756: Add PyIter_Send function (#22443)Vladimir Matveev2020-10-101-0/+5
|
* bpo-41756: Introduce PyGen_Send C API (GH-22196)Vladimir Matveev2020-09-191-0/+5
| | | | | | | | | | | | | The new API allows to efficiently send values into native generators and coroutines avoiding use of StopIteration exceptions to signal returns. ceval loop now uses this method instead of the old "private" _PyGen_Send C API. This translates to 1.6x increased performance of 'await' calls in micro-benchmarks. Aside from CPython core improvements, this new API will also allow Cython to generate more efficient code, benefiting high-performance IO libraries like uvloop.
* bpo-41726: Update the refcounts info of PyType_FromModuleAndSpec in ↵Hai Shi2020-09-091-0/+5
| | | | | refcounts.dat (GH-22112) Update refcounts info of PyType_FromModuleAndSpec in refcounts.dat
* bpo-41123: Remove PyUnicode_AsUnicodeCopy (GH-21209)Inada Naoki2020-06-301-3/+0
|
* bpo-41123: Remove PyLong_FromUnicode() (GH-21204)Inada Naoki2020-06-291-5/+0
|
* bpo-41103: Remove old buffer protocol support (#21117)Inada Naoki2020-06-251-18/+0
| | | They are deprecated since Python 3.0.
* bpo-39973: Fix the docs for PyObject_GenericSetDict() (GH-19026)Zackery Spytz2020-03-171-1/+2
| | | | PyObject_GenericSetDict() takes three arguments, not two.
* bpo-38858: new_interpreter() reuses pycore_init_builtins() (GH-17351)Victor Stinner2019-11-221-2/+0
| | | | | | | | | new_interpreter() now calls _PyBuiltin_Init() to create the builtins module and calls _PyImport_FixupBuiltin(), rather than using _PyImport_FindBuiltin(tstate, "builtins"). pycore_init_builtins() is now responsible to initialize intepr->builtins_copy: inline _PyImport_Init() and remove this function.
* Fix typo: Pyssize_t => Py_ssize_t (GH-15411)Sergey Fedoseev2019-08-261-1/+1
|
* bpo-37221: Add PyCode_NewWithPosOnlyArgs to be used internally and set ↵Pablo Galindo2019-07-011-1/+18
| | | | | | PyCode_New as a compatibility wrapper (GH-13959) Add PyCode_NewEx to be used internally and set PyCode_New as a compatibility wrapper
* bpo-36540: Documentation for PEP570 - Python positional only arguments (#13202)Pablo Galindo2019-05-281-0/+1
| | | | | | | | | | | | | | | | | | * bpo-36540: Documentation for PEP570 - Python positional only arguments * fixup! bpo-36540: Documentation for PEP570 - Python positional only arguments * Update reference for compound statements * Apply suggestions from Carol Co-Authored-By: Carol Willing <carolcode@willingconsulting.com> * Update Doc/tutorial/controlflow.rst Co-Authored-By: Carol Willing <carolcode@willingconsulting.com> * Add extra bullet point and minor edits
* bpo-36783: Add new references for C API Documentation changes (GH-13204)Edison A2019-05-131-0/+17
|
* bpo-18085: Update refcounts.dat. (GH-11247)Serhiy Storchaka2018-12-201-332/+1206
| | | | | Fixed some errors in refcounts.dat, remove functions removed in Python 3, and add more entries for documented functions. This will add several automatically generated notes about return values.
* bpo-32077: Update refcounts.dat for Unicode object functions. (GH-11243)Mat M2018-12-191-44/+231
| | | | | | | | Makes the documentation more comprehensive in terms of indicating whether or not a function returns a new reference. Also fixes some errors and adds missing functions.
* bpo-35475: Add more PyImport* functions in refcounts.dat. (GH-11142)Serhiy Storchaka2018-12-171-0/+28
|
* Add missed details of the C API introduced in 3.7. (GH-7047)Serhiy Storchaka2018-05-221-0/+76
| | | | | | * Set the limited API version for PyImport_GetModule and PyOS_*Fork functions. * Add PyImport_GetModule and Py_UTF8Mode in PC/python3.def. * Add several functions in Doc/data/refcounts.dat.
* Add PyThread_tss_* to Doc/data/refcounts.dat. (GH-7038)Masayuki Yamamoto2018-05-221-0/+21
| | | Thread Specific Storage (TSS) API is a public C API (new in 3.7).
* bpo-10381: Add timezone to datetime C API (#5032)Paul Ganssle2018-01-241-0/+8
| | | | | | | | | | | | | | | | | | * Add timezone to datetime C API * Add documentation for timezone C API macros * Add dedicated tests for datetime type check macros * Remove superfluous C API test * Drop support for TimeZoneType in datetime C API * Expose UTC singleton to the datetime C API * Update datetime C-API documentation to include links * Add reference count information for timezone constructors
* Mark PyDict_GetItemWithError() as returning a borrowed reference. (#1818)Eric Snow2017-06-011-0/+4
|
* Issue #27186: Document PyOS_FSPath().Brett Cannon2016-06-091-0/+3
|
* Issue #24400: Introduce a distinct type for 'async def' coroutines.Yury Selivanov2015-06-221-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary of changes: 1. Coroutines now have a distinct, separate from generators type at the C level: PyGen_Type, and a new typedef PyCoroObject. PyCoroObject shares the initial segment of struct layout with PyGenObject, making it possible to reuse existing generators machinery. The new type is exposed as 'types.CoroutineType'. As a consequence of having a new type, CO_GENERATOR flag is no longer applied to coroutines. 2. Having a separate type for coroutines made it possible to add an __await__ method to the type. Although it is not used by the interpreter (see details on that below), it makes coroutines naturally (without using __instancecheck__) conform to collections.abc.Coroutine and collections.abc.Awaitable ABCs. [The __instancecheck__ is still used for generator-based coroutines, as we don't want to add __await__ for generators.] 3. Add new opcode: GET_YIELD_FROM_ITER. The opcode is needed to allow passing native coroutines to the YIELD_FROM opcode. Before this change, 'yield from o' expression was compiled to: (o) GET_ITER LOAD_CONST YIELD_FROM Now, we use GET_YIELD_FROM_ITER instead of GET_ITER. The reason for adding a new opcode is that GET_ITER is used in some contexts (such as 'for .. in' loops) where passing a coroutine object is invalid. 4. Add two new introspection functions to the inspec module: getcoroutinestate(c) and getcoroutinelocals(c). 5. inspect.iscoroutine(o) is updated to test if 'o' is a native coroutine object. Before this commit it used abc.Coroutine, and it was requested to update inspect.isgenerator(o) to use abc.Generator; it was decided, however, that inspect functions should really be tailored for checking for native types. 6. sys.set_coroutine_wrapper(w) API is updated to work with only native coroutines. Since types.coroutine decorator supports any type of callables now, it would be confusing that it does not work for all types of coroutines. 7. Exceptions logic in generators C implementation was updated to raise clearer messages for coroutines: Before: TypeError("generator raised StopIteration") After: TypeError("coroutine raised StopIteration")
* Issue #18711: Add a new `PyErr_FormatV` function, similar to `PyErr_Format` ↵Antoine Pitrou2014-09-301-0/+5
| | | | but accepting a `va_list` argument.
* Issue #20517: Removed unnecessary new (short-lived) functions from PyErr.Larry Hastings2014-02-101-16/+0
|
* Issue #20517: Functions in the os module that accept two filenamesLarry Hastings2014-02-101-2/+18
| | | | | | now register both filenames in the exception on failure. This required adding new C API functions allowing OSError exceptions to reference two filenames instead of one.
* Issue #1772673: The type of `char*` arguments now changed to `const char*`.Serhiy Storchaka2013-10-191-9/+9
|
* Issue #18085: Add missed const modifier for some entries in refcounts.dat.Serhiy Storchaka2013-07-111-76/+76
|\
| * Issue #18085: Add missed const modifier for some entries in refcounts.dat.Serhiy Storchaka2013-07-111-77/+77
| |
* | Issue #9369: The types of `char*` arguments of PyObject_CallFunction() andSerhiy Storchaka2013-05-291-4/+4
| | | | | | | | | | PyObject_CallMethod() now changed to `const char*`. Based on patches by Jörg Müller and Lars Buitinck.
* | Issue #18085: Fix PyObject_CallMethodObjArgs()'s entry in refcounts.dat.Serhiy Storchaka2013-05-281-1/+1
|\ \ | |/
| * Issue #18085: Fix PyObject_CallMethodObjArgs()'s entry in refcounts.dat.Serhiy Storchaka2013-05-281-1/+1
| |
* | Add PyDict_SetDefault. (closes #17327)Benjamin Peterson2013-03-081-0/+5
|/ | | | Patch by Stefan Behnel and I.
* Merge: Remove already dropped function PySys_GetFile from documentation.Andrew Svetlov2012-10-311-4/+0
|\ | | | | | | Thanks to Daniel Müllner from docs@
| * Remove already dropped function PySys_GetFile from documentation.Andrew Svetlov2012-10-311-4/+0
| | | | | | | | Thanks to Daniel Müllner from docs@
* | PEP 3155 / issue #13448: Qualified name for classes and functions.Antoine Pitrou2011-11-251-0/+5
|/
* Add the green "New reference" note to the doc of PyException_GetTraceback()Petri Lehtinen2011-10-231-0/+2
|