deprecating types after colon

This commit is contained in:
Dmitry Jemerov
2015-04-21 18:32:31 +02:00
parent b7a4b3c17d
commit f374eec8f1
268 changed files with 1055 additions and 769 deletions
+3 -1
View File
@@ -1,3 +1,5 @@
import java.util.Collections
val ab = Collections.emptyList<Int>() : List<Int>?
fun <T> checkSubtype(t: T) = t
val ab = checkSubtype<List<Int>?>(Collections.emptyList<Int>())
@@ -1,18 +1,20 @@
class Foo(var bar : Int, var barr : Int, var barrr : Int) {
init {
bar = 1
barr = 1
barrr = 1
1 : Int
this : Foo
}
fun <T> checkSubtype(t: T) = t
init {
bar = 1
this.bar
1 : Int
val <warning>a</warning> : Int =1
this : Foo
}
class Foo(var bar : Int, var barr : Int, var barrr : Int) {
init {
bar = 1
barr = 1
barrr = 1
checkSubtype<Int>(1)
checkSubtype<Foo>(this)
}
init {
bar = 1
this.bar
checkSubtype<Int>(1)
val <warning>a</warning> : Int =1
checkSubtype<Foo>(this)
}
}