File tree Expand file tree Collapse file tree 2 files changed +3
-4
lines changed Expand file tree Collapse file tree 2 files changed +3
-4
lines changed Original file line number Diff line number Diff line change 3030)
3131from mypy .state import state
3232from mypy .types import (
33- ENUM_REMOVED_PROPS ,
3433 AnyType ,
3534 CallableType ,
3635 ExtraAttrs ,
@@ -879,8 +878,7 @@ class Status(Enum):
879878 elif isinstance (typ , Instance ) and typ .type .fullname == target_fullname :
880879 if typ .type .is_enum :
881880 return make_simplified_union (
882- [LiteralType (name , typ ) for name in typ .get_enum_values ()],
883- contract_literals = False ,
881+ [LiteralType (name , typ ) for name in typ .get_enum_values ()], contract_literals = False
884882 )
885883 elif typ .type .fullname == "builtins.bool" :
886884 return make_simplified_union (
Original file line number Diff line number Diff line change @@ -1496,7 +1496,8 @@ def is_singleton_type(self) -> bool:
14961496 def get_enum_values (self ) -> list [str ]:
14971497 """Return the list of values for an Enum."""
14981498 return [
1499- name for name , sym in self .type .names .items ()
1499+ name
1500+ for name , sym in self .type .names .items ()
15001501 if (
15011502 isinstance (sym .node , mypy .nodes .Var )
15021503 and name not in ENUM_REMOVED_PROPS
You can’t perform that action at this time.
0 commit comments