Replace resolution error for suspend-conversion with call checker error

This commit is contained in:
Mikhail Zarechenskiy
2020-06-01 01:52:56 +03:00
parent eaeaf3c8a3
commit a5203428a4
18 changed files with 265 additions and 22 deletions
@@ -5,6 +5,8 @@ fun foo1(f: suspend () -> String) {}
fun foo2(f: suspend (Int) -> String) {}
fun foo3(f: suspend () -> Unit) {}
fun bar(): String = ""
fun test(
f0: suspend () -> String,
f1: () -> String,
@@ -14,10 +16,12 @@ fun test(
foo1 { "str" }
foo1(f0)
<!INAPPLICABLE_CANDIDATE!>foo1<!>(f1)
<!INAPPLICABLE_CANDIDATE!>foo2<!>(f2)
<!INAPPLICABLE_CANDIDATE!>foo3<!>(f3)
foo1(f1)
foo2(f2)
foo3(f3)
<!INAPPLICABLE_CANDIDATE!>foo1<!>(f2)
<!INAPPLICABLE_CANDIDATE!>foo1<!>(f3)
foo1(::bar)
foo1(f2)
foo1(f3)
}