Skip to content

Commit

Permalink
Fix usages of plain "type" (#451)
Browse files Browse the repository at this point in the history
  • Loading branch information
JelleZijlstra authored Nov 21, 2023
1 parent 504ef82 commit 4dda7c3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pyi.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class Error(NamedTuple):
lineno: int
col: int
message: str
type: type
type: type[PyiTreeChecker]


class TypeVarInfo(NamedTuple):
Expand Down Expand Up @@ -1336,7 +1336,7 @@ def _check_union_members(

def _check_for_Y051_violations(self, analysis: UnionAnalysis) -> None:
"""Search for redundant unions such as `str | Literal["foo"]`, etc."""
seen_builtins: set[type] = set()
seen_builtins: set[type[object]] = set()
for literal in analysis.combined_literal_members:
if not isinstance(literal, ast.Constant):
continue
Expand Down

0 comments on commit 4dda7c3

Please sign in to comment.