From 942fcc8f53ed77e38621df37e20196acd549e45c Mon Sep 17 00:00:00 2001 From: sobolevn Date: Sat, 12 Nov 2022 11:49:27 +0300 Subject: [PATCH] Use `TypeAlias` in builtins and complete a `TODO` item --- stdlib/builtins.pyi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stdlib/builtins.pyi b/stdlib/builtins.pyi index f25777eeacd2..c8ece26fc751 100644 --- a/stdlib/builtins.pyi +++ b/stdlib/builtins.pyi @@ -192,7 +192,7 @@ class super: _PositiveInteger: TypeAlias = Literal[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25] _NegativeInteger: TypeAlias = Literal[-1, -2, -3, -4, -5, -6, -7, -8, -9, -10, -11, -12, -13, -14, -15, -16, -17, -18, -19, -20] -_LiteralInteger = _PositiveInteger | _NegativeInteger | Literal[0] # noqa: Y026 # TODO: Use TypeAlias once mypy bugs are fixed +_LiteralInteger: TypeAlias = _PositiveInteger | _NegativeInteger | Literal[0] # noqa: Y026 class int: @overload