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

11 lines
267 B
Kotlin
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) {
}
fun test<U>(u: U) {
val a = A(u).<caret>Foo(u)
}