FE 1.0: Make 'suspend fun', where 'suspend' is not builtin error in 1.8

#KT-49264 Fixed
This commit is contained in:
Ilmir Usmanov
2022-03-29 06:44:03 +02:00
committed by teamcity
parent 1c2604a95e
commit f75a8109d2
9 changed files with 45 additions and 5 deletions
@@ -0,0 +1,11 @@
// LANGUAGE: +ModifierNonBuiltinSuspendFunError
// FIR_IDENTICAL
// SKIP_TXT
infix fun Int.suspend(c: () -> Unit) {}
fun foo() {
1 <!MODIFIER_FORM_FOR_NON_BUILT_IN_SUSPEND_FUN_ERROR!>suspend<!> fun () {}
1.suspend(fun () {})
}