summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* gh-91217: deprecate-sndhdr (#91806)Brett Cannon2022-04-226-16/+49
| | | | | Also inline necessary functionality from `sndhdr` into `email.mime.audio` for `MIMEAudio`. Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* bpo-46720: Add support for path-like objects to ↵Géry Ogam2022-04-225-8/+34
| | | | | multiprocessing.set_executable for Windows (GH-31279) This bring the API to be on a par with Unix-like systems.
* gh-91575: Add a script for generating data for case-insensitive matching in ↵Serhiy Storchaka2022-04-225-57/+212
| | | | | re (GH-91660) Also test that all extra cases are in BMP.
* gh-91700: Validate the group number in conditional expression in RE (GH-91702)Serhiy Storchaka2022-04-223-0/+16
| | | | | | In expression (?(group)...) an appropriate re.error is now raised if the group number refers to not defined group. Previously it raised RuntimeError: invalid SRE code.
* gh-90568: Fix exception type for \N with a named sequence in RE (GH-91665)Serhiy Storchaka2022-04-223-2/+9
| | | re.error is now raised instead of TypeError.
* gh-89279: In ceval.c, redefine some macros for speed (#32387)Guido van Rossum2022-04-222-13/+61
| | | | | | | | | | | Macros Py_DECREF, Py_XDECREF, Py_IS_TYPE, _Py_atomic_load_32bit_impl and _Py_DECREF_SPECIALIZED are redefined as macros that completely replace the inline functions of the same name. These three came out in the top four of functions that (in MSVC) somehow weren't inlined. Co-authored-by: Victor Stinner <vstinner@python.org> Co-authored-by: Dennis Sweeney <36520290+sweeneyde@users.noreply.github.com>
* gh-91764: Mark version typing.Unpack and LiteralString were added in (#91817)Dominic Davis-Foster2022-04-221-0/+4
| | | Closes GH-91764
* gh-89653: PEP 670: Amend docs (GH-91813)Erlend Egeberg Aasland2022-04-224-17/+18
|
* gh-80527: Deprecate PEP 623 Unicode functions (#91801)Victor Stinner2022-04-222-5/+14
| | | | | | | | | | | Deprecate functions: * PyUnicode_AS_DATA() * PyUnicode_AS_UNICODE() * PyUnicode_GET_DATA_SIZE() * PyUnicode_GET_SIZE() Previously, these functions were macros and so it wasn't possible to decorate them with Py_DEPRECATED().
* Docs: Clarify availability of PyOS_CheckStack (GH-91816)Petr Viktorin2022-04-222-3/+4
|
* gh-91291: Accept attributes as keyword arguments in decimal.localcontext ↵Sam Ezeh2022-04-226-62/+161
| | | | | (#32242) Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* bpo-43224: Implement pickling of TypeVarTuples (#32119)Matthew Rahtz2022-04-222-7/+74
| | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* gh-91217: deprecate-pipes (GH-91779)Brett Cannon2022-04-224-1/+8
|
* gh-69093: Add indexing and slicing support to sqlite3.Blob (#91599)Erlend Egeberg Aasland2022-04-225-16/+349
| | | | Authored-by: Aviv Palivoda <palaviv@gmail.com> Co-authored-by: Erlend E. Aasland <erlend.aasland@innova.no>
* gh-91156: Use `locale.getencoding()` instead of getpreferredencoding (GH-91732)Inada Naoki2022-04-2214-44/+29
| | | Co-authored-by: Victor Stinner <vstinner@python.org>
* gh-89653: Add assertions to unicodeobject.h functions (#91800)Victor Stinner2022-04-211-0/+7
|
* gh-89653: PEP 670: Convert unicodeobject.h macros to functions (#91799)Victor Stinner2022-04-211-18/+44
| | | | | | | | | | | | Convert unicodeobject.h macros to static inline functions: * PyUnicode_AS_DATA() * PyUnicode_AS_UNICODE() * PyUnicode_GET_DATA_SIZE() * PyUnicode_GET_SIZE() Static inline functions are wrapped by macros which casts arguments with _PyObject_CAST() to prevent introducing new compiler warnings when passing "const PyObject*".
* gh-89373: _Py_Dealloc() checks tp_dealloc exception (#32357)Victor Stinner2022-04-214-3/+50
| | | | If Python is built in debug mode, _Py_Dealloc() now ensures that the tp_dealloc function leaves the current exception unchanged.
* gh-79315: Add Include/cpython/pythread.h header (#91798)Victor Stinner2022-04-215-44/+50
|
* gh-79315: Add Include/cpython/modsupport.h header (#91797)Victor Stinner2022-04-215-106/+118
|
* gh-89653: PEP 670: Group deprecated API in unicodeobject.h (#91796)Victor Stinner2022-04-211-56/+58
|
* gh-91768: C API no longer use "const PyObject*" type (#91769)Victor Stinner2022-04-215-26/+32
| | | | | | | | | | | | | Py_REFCNT(), Py_TYPE(), Py_SIZE() and Py_IS_TYPE() functions argument type is now "PyObject*", rather than "const PyObject*". * Replace also "const PyObject*" with "PyObject*" in functions: * _Py_strhex_impl() * _Py_strhex_with_sep() * _Py_strhex_bytes_with_sep() * Remove _PyObject_CAST_CONST() and _PyVarObject_CAST_CONST() macros. * Py_IS_TYPE() can now use Py_TYPE() in its implementation.
* gh-89653: PEP 670: Convert unicodeobject.h macros to functions (#91773)Victor Stinner2022-04-211-57/+74
| | | | | | | | | | | | | | | | | Convert unicodeobject.h macros to static inline functions: * PyUnicode_MAX_CHAR_VALUE() * PyUnicode_READ() * PyUnicode_READY() * PyUnicode_READ_CHAR() * PyUnicode_WRITE() Move PyUnicode_READY() after _PyUnicode_Ready(), since it uses _PyUnicode_Ready(). Static inline functions are wrapped by macros which casts arguments with _PyObject_CAST() and casts 'kind' arguments to "unsigned int" to prevent introducing new compiler warnings when passing "const PyObject*".
* GH-91719: Make MSVC generate somewhat faster switch code (#91718)Guido van Rossum2022-04-214-3/+90
| | | | | | | | | | | Apparently a switch on an 8-bit quantity where all cases are present generates a more efficient jump (doing only one indexed memory load instead of two). So we make opcode and use_tracing uint8_t, and generate a macro full of extra `case NNN:` lines for all unused opcodes. See https://github.com/faster-cpython/ideas/issues/321#issuecomment-1103263673
* GH-88116: Document that PyCodeNew is dangerous, and make PyCode_NewEmpty ↵Mark Shannon2022-04-214-7/+39
| | | | less dangerous. (GH-91790)
* GH-88756: Update docs for PEP 523 eval function type. (GH-91788)Mark Shannon2022-04-212-1/+8
|
* bpo-47169: Export PyOS_CheckStack on Windows (GH-32414)Petr Viktorin2022-04-213-0/+3
|
* GH-88116: Use a compact format to represent end line and column offsets. ↵Mark Shannon2022-04-2120-533/+853
| | | | | | | | | | | | (GH-91666) * Stores all location info in linetable to conform to PEP 626. * Remove column table from code objects. * Remove end-line table from code objects. * Document new location table format
* gh-89653: PEP 670: Convert tuple macros to functions (#91786)Victor Stinner2022-04-212-11/+29
| | | | | | | | | | | | | | Convert macros to static inline functions: * PyTuple_GET_SIZE() * PyTuple_SET_ITEM() * PyList_GET_SIZE() * PyList_SET_ITEM() Add a macro converting arguments to PyTupleObject*, PyListObject* or PyObject* to prevent emitting new compiler warnings. According to PEP 670, PyTuple_GET_ITEM() and PyList_GET_ITEM() are left as macros.
* gh-91782: Define static_assert() macro on FreeBSD (#91787)Victor Stinner2022-04-211-0/+9
| | | | | On FreeBSD, if the static_assert() macro is not defined, define it in Python until <sys/cdefs.h> supports C11: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=255290
* gh-89653: PEP 670: Convert PyWeakref_GET_OBJECT() to function (#91785)Victor Stinner2022-04-211-10/+16
| | | | | | Convert the PyWeakref_GET_OBJECT() macro to a static inline function. Add an assertion to check the argument with PyWeakref_Check(). Add a macro converting the argument to PyObject* to prevent emitting new compiler warning.
* gh-91636: Don't clear required fields of function objects (GH-91651)Dennis Sweeney2022-04-213-3/+79
|
* bpo-42066: CookieJar cookies should not be sorted (GH-22745)Iman Kermani2022-04-213-12/+9
|
* gh-90623: signal.raise_signal() calls PyErr_CheckSignals() (#91756)Victor Stinner2022-04-213-1/+19
| | | | signal.raise_signal() and os.kill() now call PyErr_CheckSignals() to check immediately for pending signals.
* Revert "gh-85567: Register a cleanup function to close files for FileType ↵Victor Stinner2022-04-213-11/+3
| | | | | objects in argparse (#32257)" (#91771) This reverts commit 328dbc051f84bd5fdf61101bb4fa61d85f8b7feb.
* gh-89653: PEP 670: Convert unicodeobject.h macros to functions (#91705)Victor Stinner2022-04-211-41/+61
| | | | | | | | | | | | | | | | | | Convert unicodeobject.h macros to static inline functions: * PyUnicode_CHECK_INTERNED() * PyUnicode_DATA(), _PyUnicode_COMPACT_DATA(), _PyUnicode_NONCOMPACT_DATA() * PyUnicode_GET_LENGTH() * PyUnicode_IS_ASCII() * PyUnicode_IS_COMPACT() * PyUnicode_IS_COMPACT_ASCII() * PyUnicode_IS_READY() Reorder functions to declare functions before their first usage. Static inline functions are wrapped by macros which casts arguments with _PyObject_CAST() to prevent introducing new compiler warnings when passing "const PyObject*".
* Minor improvements to grammar and markup. (GH-91762)Raymond Hettinger2022-04-201-12/+12
|
* Fix typo in GH Issue template (GH-91759)Mariatta Wijaya2022-04-201-2/+2
| | | Typo in the word enhancement.
* gh-91731: Replace Py_BUILD_ASSERT() with static_assert() (#91730)Victor Stinner2022-04-2010-38/+68
| | | | | | | | | | | | Python 3.11 now uses C11 standard which adds static_assert() to <assert.h>. * In pytime.c, replace Py_BUILD_ASSERT() with preprocessor checks on SIZEOF_TIME_T with #error. * On macOS, py_mach_timebase_info() now accepts timebase members with the same size than _PyTime_t. * py_get_monotonic_clock() now saturates GetTickCount64() to _PyTime_MAX: GetTickCount64() is unsigned, whereas _PyTime_t is signed.
* bpo-23747: Enhance platform doc, document default behavior (GH-31462)slateny2022-04-201-6/+8
|
* Cast to (destructor) to fix compiler warnings (GH-91711)Dennis Sweeney2022-04-202-12/+12
|
* build(deps): bump actions/upload-artifact from 2.3.1 to 3 (#32227)dependabot[bot]2022-04-201-1/+1
| | | | | | | | | | | | | | | | | Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 2.3.1 to 3. - [Release notes](https://github.com/actions/upload-artifact/releases) - [Commits](https://github.com/actions/upload-artifact/compare/v2.3.1...v3) --- updated-dependencies: - dependency-name: actions/upload-artifact dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* build(deps): bump actions/cache from 2.1.7 to 3.0.1 (#32228)dependabot[bot]2022-04-201-3/+3
| | | | | | | | | | | | | | | | | | Bumps [actions/cache](https://github.com/actions/cache) from 2.1.7 to 3.0.1. - [Release notes](https://github.com/actions/cache/releases) - [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md) - [Commits](https://github.com/actions/cache/compare/v2.1.7...v3.0.1) --- updated-dependencies: - dependency-name: actions/cache dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* gh-91632: Fix generic_alias_iterator to be finalized at exit. (GH-91727)Dong-hee Na2022-04-203-2/+7
|
* gh-89770: [PEP-678] add exception notes to tutorial (GH-30441)Irit Katriel2022-04-202-0/+72
|
* gh-91731: Build Python with -std=c11 (#91733)Victor Stinner2022-04-203-2/+4
| | | | Python is now built with "-std=c11" compiler option, rather than "-std=c99".
* gh-91734: Fix ossaudio support on Solaris (GH-91735)Jakub Kulík2022-04-202-0/+5
|
* bpo-30718: Add information about text buffering (GH-32351)slateny2022-04-201-1/+5
|
* Clean-up the argparse docs quick links table (GH-91726)Raymond Hettinger2022-04-201-55/+33
|
* gh-91020: Add `PyBytes_Type.tp_alloc` for subclass (GH-91686)Inada Naoki2022-04-202-1/+22
|