Skip to content

Commit b916294

Browse files
committed
pythongh-94309: Deprecate typing.Hashable/Sized
To be consistent with PEP 585, deprecated aliases should not raise any DeprecationWarning.
1 parent 760b8cf commit b916294

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Doc/library/typing.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2215,6 +2215,9 @@ Corresponding to other types in :mod:`collections.abc`
22152215

22162216
An alias to :class:`collections.abc.Hashable`.
22172217

2218+
.. deprecated:: 3.12
2219+
:class:`collections.abc.Hashable` should be directly imported from the original module.
2220+
22182221
.. class:: Reversible(Iterable[T_co])
22192222

22202223
A generic version of :class:`collections.abc.Reversible`.
@@ -2227,6 +2230,9 @@ Corresponding to other types in :mod:`collections.abc`
22272230

22282231
An alias to :class:`collections.abc.Sized`.
22292232

2233+
.. deprecated:: 3.12
2234+
:class:`collections.abc.Sized` should be directly imported from the original module.
2235+
22302236
Asynchronous programming
22312237
""""""""""""""""""""""""
22322238

0 commit comments

Comments
 (0)