Files
kotlin-fork/idea/testData/quickfix/createFromUsage/createClass/callExpression/callWithGenericReceiver.kt.after
T

14 lines
298 B
Plaintext
Vendored

// "Create class 'Foo'" "true"
// ERROR: Type inference failed: constructor Foo<U>(u: U)<br>cannot be applied to<br>(U)<br>
// ERROR: Type mismatch: inferred type is U but U was expected
class A<T>(val n: T) {
inner class Foo<U>(u: U) {
}
}
fun test<U>(u: U) {
val a = A(u).Foo(u)
}