Parameters of function types are always considered local

This commit is contained in:
Pavel V. Talanov
2016-03-01 19:53:34 +03:00
parent e121ef0fdc
commit 363d545bd5
3 changed files with 36 additions and 1 deletions
+24
View File
@@ -0,0 +1,24 @@
fun <K, V> intercept(<warning>block</warning>: (key: K, next: (K) -> V, K) -> V) {
}
fun <T : (Int) -> String> f() {
}
fun <T> g() where T: (unit: Unit) -> Unit {
}
class C<T : (Int) -> String>() {
}
class CC<T>() where T : (Int) -> String {
}
interface I<T>
val c = object : I<(String) -> String> {}
class CCC() : I<(Int) -> Int>