You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This example should give an error with --strict-equality:
defreturns_a_or_b() ->Literal['a', 'b']:
...
ifreturns_a_or_b() =='c': # This can never by True
...
this depends on the implementation of type narrowing by equality checks, see #5935. Basically, Literal[...].__eq__() should provide a literal context for its argument.
The text was updated successfully, but these errors were encountered:
This example should give an error with
--strict-equality
:this depends on the implementation of type narrowing by equality checks, see #5935. Basically,
Literal[...].__eq__()
should provide a literal context for its argument.The text was updated successfully, but these errors were encountered: