instanceof
does not narrow when the class is intersected with &
#50844
Labels
Milestone
instanceof
does not narrow when the class is intersected with &
#50844
π Search Terms
instanceof
,narrow
.π Version & Regression Information
3.8.3
to to4.9.0-dev.20220919
), and I reviewed the FAQ for entries about it.β― Playground Link
Playground link with relevant code
π» Code
π Actual behavior
instanceof
does not narrow down the left side when the right side is a type using&
.π Expected behavior
It should narrow it down to
InstanceOne
, andinstance.one()
should pass.The text was updated successfully, but these errors were encountered: