Files
kotlin-fork/idea/testData/quickfix/autoImports/delegateExtensionBoth.test
T

42 lines
1.1 KiB
Plaintext
Vendored

// FILE: first.before.kt
// "Import" "true"
// ERROR: Missing 'getValue(BigTest, KProperty<*>)' method on delegate of type 'DelegateImpl<Int>'
// ERROR: Missing 'setValue(BigTest, KProperty<*>, [ERROR : Type from delegate])' method on delegate of type 'DelegateImpl<Int>'
package testing
import some.DelegateImpl
class BigTest {
var a by <caret>DelegateImpl<Int>()
}
// FILE: second.kt
package some
import kotlin.reflect.KProperty
class DelegateImpl<T> {
val value: T = null!!
}
public operator fun <T> DelegateImpl<T>.getValue(thisRef: Any?, property: KProperty<*>): T = value
public operator fun <T> DelegateImpl<T>.setValue(thisRef: Any, property: KProperty<*>, t: T) {}
// FILE: first.after.kt
// "Import" "true"
// ERROR: Missing 'getValue(BigTest, KProperty<*>)' method on delegate of type 'DelegateImpl<Int>'
// ERROR: Missing 'setValue(BigTest, KProperty<*>, [ERROR : Type from delegate])' method on delegate of type 'DelegateImpl<Int>'
package testing
import some.DelegateImpl
import some.getValue
import some.setValue
class BigTest {
var a by <caret>DelegateImpl<Int>()
}