]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-91621: Fix typing.get_type_hints for collections.abc.Callable (#91656)
authorShantanu <12621235+hauntsaninja@users.noreply.github.com>
Mon, 2 May 2022 23:08:28 +0000 (17:08 -0600)
committerGitHub <noreply@github.com>
Mon, 2 May 2022 23:08:28 +0000 (17:08 -0600)
commitebb8b512e959ca1a0a506ac0f0faf461b1b2ff85
treef0e20c41c7c0c2e504d2f901f2b8dbcafbea8f58
parentaff8c4f4884fe5ffb2059c2ac9485ded3bba3f3c
gh-91621: Fix typing.get_type_hints for collections.abc.Callable (#91656)

This mirrors logic in typing.get_args. The trickiness comes from how we
flatten args in collections.abc.Callable, see
https://bugs.python.org/issue42195
Lib/test/test_typing.py
Lib/typing.py
Misc/NEWS.d/next/Library/2022-04-18-18-55-21.gh-issue-91621.ACNlda.rst [new file with mode: 0644]