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 is a result of canonicalizing in typeCheckCheckedCast. We test equality, which uses the canonical types, which strips parens.
Even if we “fix” that, we end up in TypeChecker::isConvertibleTo(), which eventually leads to matchTypes, which eventually does the same equality test because we’re testing a conversion constraint, and the code in matchTypes does not try to avoid the canonicalization in that case like it does for argument tuple conversions.
Additional Detail from JIRA
md5: 53fd0901e0a7d90f1840cd1b3ad7180a
Issue Description:
Mark Lacey <mark.lacey@apple.com> asked to create this issue. ("is" part)
I believe fooParam should have type of (Int,Int) -> () and fooTuple of type ((Int,Int)) -> (), but it seems like they have the same type:
The text was updated successfully, but these errors were encountered: