Report warning on extensions shadowed by members.
This commit is contained in:
Dmitry Petrov
2017-01-13 18:07:47 +03:00
parent ded7d5911b
commit 954204da82
62 changed files with 876 additions and 50 deletions
@@ -41,7 +41,7 @@ fun test2(z: Z) {
}
//'equals' operation
fun Z.equals(any: Any): Int { use(any); return 1 }
fun Z.<!EXTENSION_SHADOWED_BY_MEMBER!>equals<!>(any: Any): Int { use(any); return 1 }
fun test3(z: Z) {
z == <!TYPE_INFERENCE_NO_INFORMATION_FOR_PARAMETER!>newA<!>()
@@ -42,5 +42,5 @@ fun <T, C: MutableCollection<in T>> Array<T>.toCollection(result: C) : C {
return result
}
val Collection<*>.size : Int
val Collection<*>.<!EXTENSION_SHADOWED_BY_MEMBER!>size<!> : Int
get() = size