Skip to content

Commit 15e1e85

Browse files
committed
Change error message about ClassVar arg count
1 parent d52b4e3 commit 15e1e85

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mypy/typeanal.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ def visit_unbound_type(self, t: UnboundType) -> Type:
152152
if len(t.args) == 0:
153153
return AnyType(line=t.line)
154154
if len(t.args) != 1:
155-
self.fail('ClassVar[...] must have exactly one type argument', t)
155+
self.fail('ClassVar[...] must have at most one type argument', t)
156156
return AnyType()
157157
items = self.anal_array(t.args)
158158
return items[0]

0 commit comments

Comments
 (0)