K2: Don't lose constraint errors in the builder inference session

Pass constraint errors from the integration system into a candidate to
make sure it is reported later.

Related to KT-59426, KT-59437, KT-53749
#KT-55168 Submitted
This commit is contained in:
Simon Ogorodnik
2023-11-29 11:58:29 +01:00
committed by Space Team
parent cb3d65f669
commit 2f367b013a
26 changed files with 99 additions and 62 deletions
@@ -1,8 +1,8 @@
// ISSUE: KT-55168
fun foo(arg: Boolean) = buildList {
fun foo(arg: Boolean) = <!NEW_INFERENCE_ERROR!>buildList {
if (arg) {
removeLast()
} else {
add(42)
}
}
}<!>