Skip to content

Commit cf75ad7

Browse files
committed
add stack-overflowing test
1 parent 3587869 commit cf75ad7

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

crates/ty_python_semantic/resources/mdtest/pep613_type_aliases.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,22 @@ f("foo")
109109
f([1, "foo"])
110110
```
111111

112+
### Generic
113+
114+
```py
115+
from typing import TypeAlias, Generic, TypeVar, Union
116+
117+
T = TypeVar("T")
118+
119+
Alias: TypeAlias = Union[list["Alias"], int]
120+
121+
class A(Generic[T]):
122+
pass
123+
124+
class B(A[Alias]):
125+
pass
126+
```
127+
112128
### Union inside generic
113129

114130
#### With old-style union

0 commit comments

Comments
 (0)