Skip to content

Commit 1c40dad

Browse files
committed
Merge branch 'master' into use-sentinel-in-c-reduce/149083
2 parents bbae869 + 46a2c11 commit 1c40dad

43 files changed

Lines changed: 422 additions & 426 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/CODEOWNERS

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -156,16 +156,15 @@ Misc/libabigail.abignore @encukou
156156
# ----------------------------------------------------------------------------
157157

158158
# Android
159-
Android/ @mhsmith @freakboy3742
159+
Platforms/Android/ @mhsmith @freakboy3742
160160
Doc/using/android.rst @mhsmith @freakboy3742
161161
Lib/_android_support.py @mhsmith @freakboy3742
162162
Lib/test/test_android.py @mhsmith @freakboy3742
163163

164164
# iOS
165165
Doc/using/ios.rst @freakboy3742
166166
Lib/_ios_support.py @freakboy3742
167-
Apple/ @freakboy3742
168-
iOS/ @freakboy3742
167+
Platforms/Apple/ @freakboy3742
169168

170169
# macOS
171170
Mac/ @python/macos-team
@@ -176,8 +175,8 @@ Lib/test/test__osx_support.py @python/macos-team
176175
Tools/wasm/README.md @brettcannon @freakboy3742 @emmatyping
177176

178177
# WebAssembly (Emscripten)
179-
Tools/wasm/config.site-wasm32-emscripten @freakboy3742 @emmatyping
180-
Tools/wasm/emscripten @freakboy3742 @emmatyping
178+
Platforms/emscripten @freakboy3742 @emmatyping
179+
Tools/wasm/emscripten @freakboy3742 @emmatyping
181180

182181
# WebAssembly (WASI)
183182
Platforms/WASI @brettcannon @emmatyping @savannahostrowski

Doc/c-api/dict.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ Dictionary objects
151151
* If the key is present, set *\*result* to a new :term:`strong reference`
152152
to the value and return ``1``.
153153
* If the key is missing, set *\*result* to ``NULL`` and return ``0``.
154-
* On error, raise an exception and return ``-1``.
154+
* On error, raise an exception, set *\*result* to ``NULL`` and return ``-1``.
155155
156156
The first argument can be a :class:`dict` or a :class:`frozendict`.
157157

Doc/deprecations/pending-removal-in-3.16.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ Pending removal in Python 3.16
8484

8585
* :mod:`symtable`:
8686

87-
* The :meth:`Class.get_methods <symtable.Class.get_methods>` method
87+
* The :meth:`!symtable.Class.get_methods` method
8888
has been deprecated since Python 3.14.
8989

9090
* :mod:`sys`:

Doc/library/symtable.rst

Lines changed: 0 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -187,57 +187,6 @@ Examining Symbol Tables
187187

188188
A namespace of a class. This class inherits from :class:`SymbolTable`.
189189

190-
.. method:: get_methods()
191-
192-
Return a tuple containing the names of method-like functions declared
193-
in the class.
194-
195-
Here, the term 'method' designates *any* function defined in the class
196-
body via :keyword:`def` or :keyword:`async def`.
197-
198-
Functions defined in a deeper scope (e.g., in an inner class) are not
199-
picked up by :meth:`get_methods`.
200-
201-
For example:
202-
203-
.. testsetup:: symtable.Class.get_methods
204-
205-
import warnings
206-
context = warnings.catch_warnings()
207-
context.__enter__()
208-
warnings.simplefilter("ignore", category=DeprecationWarning)
209-
210-
.. testcleanup:: symtable.Class.get_methods
211-
212-
context.__exit__()
213-
214-
.. doctest:: symtable.Class.get_methods
215-
216-
>>> import symtable
217-
>>> st = symtable.symtable('''
218-
... def outer(): pass
219-
...
220-
... class A:
221-
... def f():
222-
... def w(): pass
223-
...
224-
... def g(self): pass
225-
...
226-
... @classmethod
227-
... async def h(cls): pass
228-
...
229-
... global outer
230-
... def outer(self): pass
231-
... ''', 'test', 'exec')
232-
>>> class_A = st.get_children()[2]
233-
>>> class_A.get_methods()
234-
('f', 'g', 'h')
235-
236-
Although ``A().f()`` raises :exc:`TypeError` at runtime, ``A.f`` is still
237-
considered as a method-like function.
238-
239-
.. deprecated-removed:: 3.14 3.16
240-
241190

242191
.. class:: Symbol
243192

Doc/tools/removed-ids.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,6 @@ c-api/allocation.html: deprecated-aliases
55
c-api/file.html: deprecated-api
66

77
library/asyncio-task.html: terminating-a-task-group
8+
9+
# Removed APIs
10+
library/symtable.html: symtable.Class.get_methods

Doc/whatsnew/3.14.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2718,7 +2718,7 @@ New deprecations
27182718
(Contributed by Tian Gao in :gh:`124369` and :gh:`125951`.)
27192719

27202720
* :mod:`symtable`:
2721-
Deprecate :meth:`symtable.Class.get_methods` due to the lack of interest,
2721+
Deprecate :meth:`!symtable.Class.get_methods` due to the lack of interest,
27222722
scheduled for removal in Python 3.16.
27232723
(Contributed by Bénédikt Tran in :gh:`119698`.)
27242724

Doc/whatsnew/3.15.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -411,8 +411,8 @@ embedding applications, and native libraries.
411411
unwinding for the whole Python process.
412412

413413
(Contributed by Pablo Galindo Salgado and Savannah Ostrowski in
414-
:gh:`149201`; PEP 831 written by Pablo Galindo Salgado, Ken Jin, and
415-
Savannah Ostrowski.)
414+
:gh:`149201`; PEP 831 written by Pablo Galindo Salgado, Ken Jin,
415+
Savannah Ostrowski, and Diego Russo.)
416416

417417
.. seealso:: :pep:`831` for further details.
418418

Doc/whatsnew/3.16.rst

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,18 @@ annotationlib
114114
Use :meth:`annotationlib.ForwardRef.evaluate`
115115
or :func:`typing.evaluate_forward_ref` instead.
116116

117+
functools
118+
---------
119+
120+
* Calling the Python implementation of :func:`functools.reduce` with *function*
121+
or *sequence* as keyword arguments has been deprecated since Python 3.14.
122+
123+
symtable
124+
--------
125+
126+
* The :meth:`!symtable.Class.get_methods` method
127+
which has been deprecated since Python 3.14.
128+
117129
sysconfig
118130
---------
119131

Include/internal/pycore_bytesobject.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,11 @@ _PyBytes_ReverseFind(const char *haystack, Py_ssize_t len_haystack,
6262
//
6363
// Export for 'array' shared extension.
6464
PyAPI_FUNC(void)
65-
_PyBytes_Repeat(char* dest, Py_ssize_t len_dest,
65+
_PyBytes_RepeatBuffer(char* dest, Py_ssize_t len_dest,
6666
const char* src, Py_ssize_t len_src);
6767

68+
PyAPI_FUNC(PyObject *) _PyBytes_Repeat(PyObject *self, Py_ssize_t n);
69+
6870
/* _PyBytesObject_SIZE gives the basic size of a bytes object; any memory allocation
6971
for a bytes object of length n should request PyBytesObject_SIZE + n bytes.
7072

Include/internal/pycore_tuple.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ PyAPI_FUNC(PyObject *)_PyTuple_FromStackRefStealOnSuccess(const union _PyStackRe
2929
PyAPI_FUNC(PyObject *)_PyTuple_FromArraySteal(PyObject *const *, Py_ssize_t);
3030
PyAPI_FUNC(PyObject *) _PyTuple_BinarySlice(PyObject *, PyObject *, PyObject *);
3131
PyAPI_FUNC(PyObject *) _PyTuple_Concat(PyObject *, PyObject *);
32+
PyAPI_FUNC(PyObject *) _PyTuple_Repeat(PyObject *self, Py_ssize_t n);
3233

3334
PyAPI_FUNC(PyObject *) _PyTuple_FromPair(PyObject *, PyObject *);
3435
PyAPI_FUNC(PyObject *) _PyTuple_FromPairSteal(PyObject *, PyObject *);

0 commit comments

Comments
 (0)