Skip to content

Commit

Permalink
Fix __match_args__ for TypeVarLikeExpr
Browse files Browse the repository at this point in the history
  • Loading branch information
cdce8p committed Jun 7, 2023
1 parent 13b8f84 commit 20f2c17
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions mypy/nodes.py
Original file line number Diff line number Diff line change
Expand Up @@ -2493,7 +2493,7 @@ class TypeVarExpr(TypeVarLikeExpr):

__slots__ = ("values",)

__match_args__ = ("name", "values", "upper_bound")
__match_args__ = ("name", "values", "upper_bound", "default")

# Value restriction: only types in the list are valid as values. If the
# list is empty, there is no restriction.
Expand Down Expand Up @@ -2541,7 +2541,7 @@ def deserialize(cls, data: JsonDict) -> TypeVarExpr:
class ParamSpecExpr(TypeVarLikeExpr):
__slots__ = ()

__match_args__ = ("name", "upper_bound")
__match_args__ = ("name", "upper_bound", "default")

def accept(self, visitor: ExpressionVisitor[T]) -> T:
return visitor.visit_paramspec_expr(self)
Expand Down Expand Up @@ -2575,7 +2575,7 @@ class TypeVarTupleExpr(TypeVarLikeExpr):

tuple_fallback: mypy.types.Instance

__match_args__ = ("name", "upper_bound")
__match_args__ = ("name", "upper_bound", "default")

def __init__(
self,
Expand Down

0 comments on commit 20f2c17

Please sign in to comment.