Suspend call detector: fix delegated properties checking

This commit is contained in:
Mikhail Glukhikh
2017-12-07 11:46:04 +03:00
parent 24bd31457c
commit e503c1d411
9 changed files with 102 additions and 4 deletions
@@ -0,0 +1,8 @@
fun bar(d: Delegate): String {
val x: String by <!ILLEGAL_SUSPEND_FUNCTION_CALL!>d<!>
return x
}
class Delegate {
suspend operator fun getValue(thisRef: Any?, property: Any?): String = ""
}
@@ -0,0 +1,11 @@
package
public fun bar(/*0*/ d: Delegate): kotlin.String
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator suspend fun getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ property: kotlin.Any?): kotlin.String
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}