Commit 48ffedd
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://882856821 parent 0c90aac commit 48ffedd
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 | |
|---|---|---|---|
| |||
8802 | 8802 | | |
8803 | 8803 | | |
8804 | 8804 | | |
8805 | | - | |
| 8805 | + | |
8806 | 8806 | | |
8807 | 8807 | | |
8808 | 8808 | | |
| |||
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