Commit 04ec6a9
committed
[CSApply] Result coercion check should always use resolved type
`shouldCoerceToContextualType` used `solution.getType(ASTNode)`
which returns a type that has type variables in it. To properly
check whether result type needs a coercion it has to be resolved
first which is done via `solution.getResultType(ASTNode)`.
Resolves: rdar://88285682
(cherry picked from commit 48ffedd)1 parent cbcaff4 commit 04ec6a9
File tree
2 files changed
+20
-1
lines changed- lib/Sema
- validation-test/Sema/type_checker_crashers_fixed
2 files changed
+20
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8695 | 8695 | | |
8696 | 8696 | | |
8697 | 8697 | | |
8698 | | - | |
| 8698 | + | |
8699 | 8699 | | |
8700 | 8700 | | |
8701 | 8701 | | |
| |||
Lines changed: 19 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
0 commit comments