Warning "value of type parameter is predetermined" is no more generated for sealed bound #KT-9244 Fixed
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
// See KT-9244
|
||||
|
||||
sealed class Foo {
|
||||
class Bar : Foo()
|
||||
class Baz : Foo()
|
||||
}
|
||||
|
||||
// The following warning seems incorrect here
|
||||
// "Foo is a final type, and thus a value of the type parameter is predetermined"
|
||||
fun <T : Foo> doit(arg: T): T = arg
|
||||
Reference in New Issue
Block a user