]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-98602: [typing docs] Use quotes for forward reference in TypeVarTuple example...
authorEclips4 <80244920+Eclips4@users.noreply.github.com>
Tue, 25 Oct 2022 15:32:52 +0000 (18:32 +0300)
committerGitHub <noreply@github.com>
Tue, 25 Oct 2022 15:32:52 +0000 (16:32 +0100)
Doc/library/typing.rst

index ead7835bfffa66eeec1927abd6ce7498e06d8313..8c8286059d531e6babd163476ea324808b371afc 100644 (file)
@@ -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::