Skip to content

Commit c0b6185

Browse files
committed
Document that implicitly generic TypedDict aliases are not supported
1 parent 62e2ee6 commit c0b6185

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

test-data/unit/check-typeddict.test

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4216,6 +4216,11 @@ _T = TypeVar("_T")
42164216
class A(Generic[_T], TypedDict):
42174217
x: _T
42184218

4219+
# This is by design - no_args aliases are only supported for instances
4220+
A0 = A
4221+
class B(A0[str]): # E: Bad number of arguments for type alias, expected 0, given 1
4222+
y: int
4223+
42194224
A1 = A[_T]
42204225
A2: TypeAlias = A[_T]
42214226
Aint = A[int]

0 commit comments

Comments
 (0)