8000 [3.12] `typing.NewType` docs: the future performance improvements are… · python/cpython@f4969eb · GitHub
[go: up one dir, main page]

Skip to content

Commit f4969eb

Browse files
[3.12] typing.NewType docs: the future performance improvements are now in the past (GH-105354) (#105414)
`typing.NewType` docs: the future performance improvements are now in the past (GH-105354) (cherry picked from commit 5f65ff0) Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
1 parent 84133c5 commit f4969eb

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

Doc/library/typing.rst

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -236,9 +236,13 @@ See :pep:`484` for more details.
236236
.. versionadded:: 3.5.2
237237

238238
.. versionchanged:: 3.10
239-
``NewType`` is now a class rather than a function. There is some additional
240-
runtime cost when calling ``NewType`` over a regular function. However, this
241-
cost will be reduced in 3.11.0.
239+
``NewType`` is now a class rather than a function. As a result, there is
240+
some additional runtime cost when calling ``NewType`` over a regular
241+
function.
242+
243+
.. versionchanged:: 3.11
244+
The performance of calling ``NewType`` has been restored to its level in
245+
Python 3.9.
242246

243247

244248
Callable

0 commit comments

Comments
 (0)
0