From d62ec00e5ba78201c536c45f33efca11c1344cff Mon Sep 17 00:00:00 2001 From: Eclips4 Date: Mon, 24 Oct 2022 18:31:26 +0300 Subject: [PATCH] gh-98602: fix return value of __abs__ method in example of TypeVarTuple --- Doc/library/typing.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/library/typing.rst b/Doc/library/typing.rst index ae7e223069962e..0c776d295f7fe8 100644 --- a/Doc/library/typing.rst +++ b/Doc/library/typing.rst @@ -1351,7 +1351,7 @@ These are not used in annotations. They are building blocks for creating generic Shape = TypeVarTuple('Shape') class Array(Generic[*Shape]): def __getitem__(self, key: tuple[*Shape]) -> float: ... - def __abs__(self) -> Array[*Shape]: ... + def __abs__(self) -> "Array[*Shape]": ... def get_shape(self) -> tuple[*Shape]: ... Type variable tuples can be happily combined with normal type variables::