Disable callable references to suspend functions in 1.2
#KT-25604: Fixed
This commit is contained in:
+2
@@ -1,3 +1,5 @@
|
||||
// !LANGUAGE: +ReleaseCoroutines
|
||||
// !API_VERSION: 1.3
|
||||
// !DIAGNOSTICS: -UNUSED_VARIABLE
|
||||
suspend fun foo() {}
|
||||
|
||||
|
||||
Vendored
+2
@@ -1,3 +1,5 @@
|
||||
// !LANGUAGE: +ReleaseCoroutines
|
||||
// !API_VERSION: 1.3
|
||||
// SKIP_TXT
|
||||
|
||||
fun <R> suspend(block: suspend () -> R): suspend () -> R = block
|
||||
|
||||
+2
@@ -1,3 +1,5 @@
|
||||
// !LANGUAGE: +ReleaseCoroutines
|
||||
// !API_VERSION: 1.3
|
||||
// SKIP_TXT
|
||||
|
||||
fun <R> suspend(block: R) = block
|
||||
|
||||
+2
@@ -1,3 +1,5 @@
|
||||
// !LANGUAGE: +ReleaseCoroutines
|
||||
// !API_VERSION: 1.3
|
||||
// SKIP_TXT
|
||||
fun bar() {
|
||||
suspend {
|
||||
|
||||
Vendored
+2
@@ -1,3 +1,5 @@
|
||||
// !LANGUAGE: +ReleaseCoroutines
|
||||
// !API_VERSION: 1.3
|
||||
// SKIP_TXT
|
||||
import kotlin.suspend as suspendLambda
|
||||
|
||||
|
||||
Reference in New Issue
Block a user