]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-98852: Fix subscription of type aliases (GH-98920)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Tue, 1 Nov 2022 08:01:28 +0000 (01:01 -0700)
committerGitHub <noreply@github.com>
Tue, 1 Nov 2022 08:01:28 +0000 (01:01 -0700)
commit20c258c6928b878e0cb63f6b792e904e18f2242f
tree6b9e989d53110b2a6169d1f055c33b4833a35116
parent217a31742544729a001dea9139cc272e64e33064
gh-98852: Fix subscription of type aliases (GH-98920)

Fix subscription of type aliases containing bare generic types or types
like TypeVar: for example tuple[A, T][int] and tuple[TypeVar, T][int],
where A is a generic type, and T is a type variable.
(cherry picked from commit 0e15c31c7e9907fdbe38a3f419b669fed5bb3b33)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Lib/test/test_typing.py
Lib/typing.py
Misc/NEWS.d/next/Core and Builtins/2022-10-31-21-01-35.gh-issue-98852.MYaRN6.rst [new file with mode: 0644]
Objects/genericaliasobject.c