FIR: Update test data (NEW_INFERENCE_ERROR)
Though these diagnostics look correct (the calls or constraint systems indeed contain errors), more precise diagnostic kinds should be chosen later.
This commit is contained in:
committed by
teamcityserver
parent
010a0c6cdc
commit
da3233c47d
compiler/testData/diagnostics/tests/inference/coercionToUnit/coercionWithExpectedTypeAndBound.fir.kt
Vendored
+2
-2
@@ -3,11 +3,11 @@
|
||||
fun <T : Number> materializeNumber(): T = TODO()
|
||||
|
||||
fun a(): Unit = run {
|
||||
materializeNumber()
|
||||
<!NEW_INFERENCE_ERROR!>materializeNumber()<!>
|
||||
}
|
||||
|
||||
fun b(): Unit = run {
|
||||
run {
|
||||
materializeNumber()
|
||||
<!NEW_INFERENCE_ERROR!>materializeNumber()<!>
|
||||
}
|
||||
}
|
||||
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
// !DIAGNOSTICS: -UNUSED_PARAMETER
|
||||
|
||||
interface Base
|
||||
class Foo : Base
|
||||
|
||||
fun <T : Base> myRun(action: () -> T): T = action()
|
||||
|
||||
fun foo(f: (Foo) -> Unit) {}
|
||||
|
||||
fun main() {
|
||||
foo { f: Foo ->
|
||||
<!NEW_INFERENCE_ERROR!>myRun { f }<!>
|
||||
}
|
||||
}
|
||||
+1
-2
@@ -1,4 +1,3 @@
|
||||
// FIR_IDENTICAL
|
||||
// !DIAGNOSTICS: -UNUSED_PARAMETER
|
||||
|
||||
interface Base
|
||||
@@ -12,4 +11,4 @@ fun main() {
|
||||
foo { f: Foo ->
|
||||
myRun { f }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user