Deprecate PropertyMetadata, use KProperty<*> for delegated properties instead

This commit is contained in:
Alexander Udalov
2015-10-12 21:42:18 +03:00
parent 3c74f48f91
commit ec1b4776fe
145 changed files with 536 additions and 379 deletions
@@ -1,9 +1,11 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val a: Int by Delegate()
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
}
@@ -5,7 +5,7 @@ public val a: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,9 +1,11 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val a by Delegate()
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
}
@@ -5,7 +5,7 @@ public val a: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,11 +1,13 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
abstract class A {
abstract val a: Int <!ABSTRACT_DELEGATED_PROPERTY!>by Delegate()<!>
}
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
}
@@ -11,7 +11,7 @@ public abstract class A {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class B {
val a: Int by Delegate()
@@ -7,8 +9,7 @@ class B {
}
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
@@ -12,7 +12,7 @@ public final class B {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,10 +1,12 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val a: Int by Delegate()
get
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
}
@@ -5,7 +5,7 @@ public val a: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,12 +1,14 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
var a: Int by Delegate()
private set
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
operator fun setValue(t: Any?, p: PropertyMetadata, i: Int) {}
}
operator fun setValue(t: Any?, p: KProperty<*>, i: Int) {}
}
@@ -5,8 +5,8 @@ public var a: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ i: kotlin.Int): kotlin.Unit
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ i: kotlin.Int): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
interface A {
val prop: Int
}
@@ -13,7 +15,7 @@ fun foo() {
}
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
@@ -20,7 +20,7 @@ public final class AImpl : A {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
interface A {
val prop: Int
}
@@ -13,7 +15,7 @@ fun foo() {
}
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): String {
operator fun getValue(t: Any?, p: KProperty<*>): String {
return ""
}
}
@@ -20,7 +20,7 @@ public final class AImpl : A {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.String
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.String
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
import kotlin.reflect.KProperty0
val a: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>A()<!>
class A {
fun getValue(t: Any?, p: PropertyMetadataImpl): Int = 1
fun getValue(t: Any?, p: KProperty0<*>): Int = 1
}
@@ -5,7 +5,7 @@ public val a: kotlin.Int
public final class A {
public constructor A()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadataImpl): kotlin.Int
public final fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty0<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,10 +1,11 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val a: Int by A(1)
class A<T: Any>(i: T) {
operator fun getValue(t: Any?, p: PropertyMetadata): T {
operator fun getValue(t: Any?, p: KProperty<*>): T {
throw Exception()
}
}
@@ -5,7 +5,7 @@ public val a: kotlin.Int
public final class A</*0*/ T : kotlin.Any> {
public constructor A</*0*/ T : kotlin.Any>(/*0*/ i: T)
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): T
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,14 +1,15 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
open class Base
class Derived: Base()
val a: Base by A()
class A {
operator fun getValue(t: Any?, p: PropertyMetadata): Derived {
operator fun getValue(t: Any?, p: KProperty<*>): Derived {
return Derived()
}
}
@@ -5,7 +5,7 @@ public val a: Base
public final class A {
public constructor A()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): Derived
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): Derived
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,11 +1,13 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
interface T {
val a: Int <!DELEGATED_PROPERTY_IN_INTERFACE!>by Delegate()<!>
}
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
@@ -3,7 +3,7 @@ package
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class A
class D {
@@ -9,7 +11,7 @@ class D {
val cTopLevel: Int by <!DELEGATE_SPECIAL_FUNCTION_MISSING!>IncorrectThis<A>()<!>
class IncorrectThis<T> {
fun <R> get(t: Any?, p: PropertyMetadata): Int {
fun <R> get(t: Any?, p: KProperty<*>): Int {
return 1
}
}
}
@@ -20,7 +20,7 @@ public final class D {
public final class IncorrectThis</*0*/ T> {
public constructor IncorrectThis</*0*/ T>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final fun </*0*/ R> get(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final fun </*0*/ R> get(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
package baz
import kotlin.reflect.KProperty
class A(outer: Outer) {
var i: String by + getMyConcreteProperty()
var d: String by getMyConcreteProperty() - 1
@@ -21,12 +23,12 @@ fun getMyConcreteProperty() = MyProperty<Any?, String>()
class MyProperty<R, T> {
operator fun getValue(thisRef: R, desc: PropertyMetadata): T {
operator fun getValue(thisRef: R, desc: KProperty<*>): T {
println("get $thisRef ${desc.name}")
return null as T
}
operator fun setValue(thisRef: R, desc: PropertyMetadata, value: T) {
operator fun setValue(thisRef: R, desc: KProperty<*>, value: T) {
println("set $thisRef ${desc.name} $value")
}
}
@@ -47,4 +49,4 @@ interface Outer {
}
// -----------------
fun println(a: Any?) = a
fun println(a: Any?) = a
@@ -26,9 +26,9 @@ package baz {
public final class MyProperty</*0*/ R, /*1*/ T> {
public constructor MyProperty</*0*/ R, /*1*/ T>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.PropertyMetadata): T
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.PropertyMetadata, /*2*/ value: T): kotlin.Unit
public final operator fun setValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.reflect.KProperty<*>, /*2*/ value: T): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,11 +1,13 @@
package foo
import kotlin.reflect.KProperty
class A1 {
val a: String by MyProperty1()
}
class MyProperty1 {}
operator fun MyProperty1.getValue(thisRef: Any?, desc: PropertyMetadata): String {
operator fun MyProperty1.getValue(thisRef: Any?, desc: KProperty<*>): String {
throw Exception("$thisRef $desc")
}
@@ -16,7 +18,7 @@ class A2 {
}
class MyProperty2<T> {}
operator fun <T> MyProperty2<T>.getValue(thisRef: Any?, desc: PropertyMetadata): T {
operator fun <T> MyProperty2<T>.getValue(thisRef: Any?, desc: KProperty<*>): T {
throw Exception("$thisRef $desc")
}
@@ -27,7 +29,7 @@ class A3 {
class MyProperty3<T> {}
operator fun <T> MyProperty3<T>.getValue(thisRef: Any?, desc: PropertyMetadata): T {
operator fun <T> MyProperty3<T>.getValue(thisRef: Any?, desc: KProperty<*>): T {
throw Exception("$thisRef $desc")
}
}
}
@@ -1,8 +1,8 @@
package
package foo {
public operator fun foo.MyProperty1.getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.PropertyMetadata): kotlin.String
public operator fun </*0*/ T> foo.MyProperty2<T>.getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.PropertyMetadata): T
public operator fun foo.MyProperty1.getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.reflect.KProperty<*>): kotlin.String
public operator fun </*0*/ T> foo.MyProperty2<T>.getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public final class A1 {
public constructor A1()
@@ -26,7 +26,7 @@ package foo {
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
public final operator fun </*0*/ T> foo.A3.MyProperty3<T>.getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.PropertyMetadata): T
public final operator fun </*0*/ T> foo.A3.MyProperty3<T>.getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public final class MyProperty3</*0*/ T> {
public constructor MyProperty3</*0*/ T>()
@@ -1,5 +1,7 @@
package foo
import kotlin.reflect.KProperty
open class A {
val B.w: Int by <!TYPE_INFERENCE_UPPER_BOUND_VIOLATED!>MyProperty<!>()
}
@@ -13,7 +15,7 @@ class B {
}
class MyProperty<R : A, T> {
operator fun getValue(thisRef: R, desc: PropertyMetadata): T {
operator fun getValue(thisRef: R, desc: KProperty<*>): T {
throw Exception("$thisRef $desc")
}
}
@@ -23,7 +23,7 @@ package foo {
public final class MyProperty</*0*/ R : foo.A, /*1*/ T> {
public constructor MyProperty</*0*/ R : foo.A, /*1*/ T>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.PropertyMetadata): T
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,24 +1,26 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class A<R>() {
operator fun <T> getValue(t: Any?, p: PropertyMetadata): T = null!!
operator fun <T> setValue(t: Any?, p: PropertyMetadata, x: T) = Unit
operator fun <T> getValue(t: Any?, p: KProperty<*>): T = null!!
operator fun <T> setValue(t: Any?, p: KProperty<*>, x: T) = Unit
}
var a1: Int by <!TYPE_INFERENCE_NO_INFORMATION_FOR_PARAMETER!>A<!>()
var a2: Int by A<String>()
class B<R>() {
operator fun <T> getValue(t: Any?, p: PropertyMetadata): T = null!!
operator fun setValue(t: Any?, p: PropertyMetadata, x: R) = Unit
operator fun <T> getValue(t: Any?, p: KProperty<*>): T = null!!
operator fun setValue(t: Any?, p: KProperty<*>, x: R) = Unit
}
var b1: Int by B()
var b2: Int by B<Number>()
class C<R>() {
operator fun getValue(t: Any?, p: PropertyMetadata): R = null!!
operator fun <T> setValue(t: Any?, p: PropertyMetadata, x: T) = Unit
operator fun getValue(t: Any?, p: KProperty<*>): R = null!!
operator fun <T> setValue(t: Any?, p: KProperty<*>, x: T) = Unit
}
var c1: Int by C()
@@ -10,26 +10,26 @@ public var c2: kotlin.Int
public final class A</*0*/ R> {
public constructor A</*0*/ R>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun </*0*/ T> getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): T
public final operator fun </*0*/ T> getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun </*0*/ T> setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ x: T): kotlin.Unit
public final operator fun </*0*/ T> setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ x: T): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
public final class B</*0*/ R> {
public constructor B</*0*/ R>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun </*0*/ T> getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): T
public final operator fun </*0*/ T> getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ x: R): kotlin.Unit
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ x: R): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
public final class C</*0*/ R> {
public constructor C</*0*/ R>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): R
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): R
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun </*0*/ T> setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ x: T): kotlin.Unit
public final operator fun </*0*/ T> setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ x: T): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,4 +1,6 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
var a: Int by A()
var a1 by <!DELEGATE_SPECIAL_FUNCTION_MISSING, DELEGATE_SPECIAL_FUNCTION_MISSING!>A()<!>
@@ -8,16 +10,16 @@ val cObj = C()
var c: String by cObj
class A {
operator fun <T> getValue(t: Any?, p: PropertyMetadata): T = null!!
operator fun <T> setValue(t: Any?, p: PropertyMetadata, x: T) = Unit
operator fun <T> getValue(t: Any?, p: KProperty<*>): T = null!!
operator fun <T> setValue(t: Any?, p: KProperty<*>, x: T) = Unit
}
class B
operator fun <T> B.getValue(t: Any?, p: PropertyMetadata): T = null!!
operator fun <T> B.setValue(t: Any?, p: PropertyMetadata, x: T) = Unit
operator fun <T> B.getValue(t: Any?, p: KProperty<*>): T = null!!
operator fun <T> B.setValue(t: Any?, p: KProperty<*>, x: T) = Unit
class C
operator inline fun <reified T> C.getValue(t: Any?, p: PropertyMetadata): T = null!!
operator inline fun <reified T> C.setValue(t: Any?, p: PropertyMetadata, x: T) = Unit
operator inline fun <reified T> C.getValue(t: Any?, p: KProperty<*>): T = null!!
operator inline fun <reified T> C.setValue(t: Any?, p: KProperty<*>, x: T) = Unit
@@ -5,17 +5,17 @@ public var a1: [ERROR : Type from delegate]
public var b: kotlin.Int
public var c: kotlin.String
public val cObj: C
public operator fun </*0*/ T> B.getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): T
@kotlin.inline() public operator fun </*0*/ reified T> C.getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): T
public operator fun </*0*/ T> B.setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ x: T): kotlin.Unit
@kotlin.inline() public operator fun </*0*/ reified T> C.setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ x: T): kotlin.Unit
public operator fun </*0*/ T> B.getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): T
@kotlin.inline() public operator fun </*0*/ reified T> C.getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): T
public operator fun </*0*/ T> B.setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ x: T): kotlin.Unit
@kotlin.inline() public operator fun </*0*/ reified T> C.setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ x: T): kotlin.Unit
public final class A {
public constructor A()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun </*0*/ T> getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): T
public final operator fun </*0*/ T> getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun </*0*/ T> setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ x: T): kotlin.Unit
public final operator fun </*0*/ T> setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ x: T): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,9 +1,11 @@
import kotlin.reflect.KProperty
class A3 {
val a: String by l@ MyProperty()
class MyProperty<T> {}
operator fun <T> MyProperty<T>.getValue(thisRef: Any?, desc: PropertyMetadata): T {
operator fun <T> MyProperty<T>.getValue(thisRef: Any?, desc: KProperty<*>): T {
throw Exception("$thisRef $desc")
}
}
}
@@ -6,7 +6,7 @@ public final class A3 {
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
public final operator fun </*0*/ T> A3.MyProperty<T>.getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.PropertyMetadata): T
public final operator fun </*0*/ T> A3.MyProperty<T>.getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public final class MyProperty</*0*/ T> {
public constructor MyProperty</*0*/ T>()
@@ -1,5 +1,7 @@
package foo
import kotlin.reflect.KProperty
class A {
var a5: String by <!TYPE_INFERENCE_NO_INFORMATION_FOR_PARAMETER!>MyProperty1<!>()
var b5: String by <!TYPE_INFERENCE_NO_INFORMATION_FOR_PARAMETER!>getMyProperty1<!>()
@@ -9,7 +11,7 @@ fun <A, B> getMyProperty1() = MyProperty1<A, B>()
class MyProperty1<T, R> {
operator fun getValue(thisRef: R, desc: PropertyMetadata): T {
operator fun getValue(thisRef: R, desc: KProperty<*>): T {
throw Exception()
}
@@ -29,7 +31,7 @@ fun <A, B> getMyProperty2() = MyProperty2<A, B>()
class MyProperty2<T, R> {
operator fun getValue(thisRef: R, desc: PropertyMetadata): T {
operator fun getValue(thisRef: R, desc: KProperty<*>): T {
throw Exception()
}
@@ -39,4 +41,4 @@ class MyProperty2<T, R> {
}
// -----------------
fun println(a: Any?) = a
fun println(a: Any?) = a
@@ -26,7 +26,7 @@ package foo {
public final class MyProperty1</*0*/ T, /*1*/ R> {
public constructor MyProperty1</*0*/ T, /*1*/ R>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.PropertyMetadata): T
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ i: kotlin.Int, /*1*/ j: kotlin.Any, /*2*/ k: kotlin.Int): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
@@ -35,7 +35,7 @@ package foo {
public final class MyProperty2</*0*/ T, /*1*/ R> {
public constructor MyProperty2</*0*/ T, /*1*/ R>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.PropertyMetadata): T
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ i: kotlin.Int): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
@@ -1,14 +1,16 @@
import kotlin.reflect.KProperty
class A {
var a by <!TYPE_INFERENCE_NO_INFORMATION_FOR_PARAMETER!>MyProperty<!>()
}
class MyProperty<T, R> {
operator fun getValue(thisRef: R, desc: PropertyMetadata): T {
operator fun getValue(thisRef: R, desc: KProperty<*>): T {
throw Exception("$thisRef $desc")
}
operator fun setValue(thisRef: R, desc: PropertyMetadata, t: T) {
operator fun setValue(thisRef: R, desc: KProperty<*>, t: T) {
throw Exception("$thisRef $desc $t")
}
}
@@ -11,8 +11,8 @@ public final class A {
public final class MyProperty</*0*/ T, /*1*/ R> {
public constructor MyProperty</*0*/ T, /*1*/ R>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.PropertyMetadata): T
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.PropertyMetadata, /*2*/ t: T): kotlin.Unit
public final operator fun setValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.reflect.KProperty<*>, /*2*/ t: T): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !CHECK_TYPE
import kotlin.reflect.KProperty
class A {
val a by MyProperty()
@@ -9,5 +11,5 @@ class A {
}
class MyProperty<R> {
operator fun getValue(thisRef: R, desc: PropertyMetadata): Int = throw Exception("$thisRef $desc")
}
operator fun getValue(thisRef: R, desc: KProperty<*>): Int = throw Exception("$thisRef $desc")
}
@@ -12,7 +12,7 @@ public final class A {
public final class MyProperty</*0*/ R> {
public constructor MyProperty</*0*/ R>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
package foo
import kotlin.reflect.KProperty
class A1 {
var a1: String by MyProperty1()
var b1: String by getMyProperty1()
@@ -12,12 +14,12 @@ fun <A, B> getMyProperty1() = MyProperty1<A, B>()
class MyProperty1<R, T> {
operator fun getValue(thisRef: R, desc: PropertyMetadata): T {
operator fun getValue(thisRef: R, desc: KProperty<*>): T {
println("get $thisRef ${desc.name}")
throw Exception()
}
operator fun setValue(thisRef: R, desc: PropertyMetadata, value: T) {
operator fun setValue(thisRef: R, desc: KProperty<*>, value: T) {
println("set $thisRef ${desc.name} $value")
}
}
@@ -36,12 +38,12 @@ fun <A> getMyProperty2() = MyProperty2<A>()
class MyProperty2<T> {
operator fun getValue(thisRef: Any?, desc: PropertyMetadata): T {
operator fun getValue(thisRef: Any?, desc: KProperty<*>): T {
println("get $thisRef ${desc.name}")
throw Exception()
}
operator fun setValue(thisRef: Any?, desc: PropertyMetadata, value: T) {
operator fun setValue(thisRef: Any?, desc: KProperty<*>, value: T) {
println("set $thisRef ${desc.name} $value")
}
}
@@ -60,15 +62,15 @@ fun <A> getMyProperty3() = MyProperty3<A>()
class MyProperty3<T> {
operator fun getValue(thisRef: T, desc: PropertyMetadata): String {
operator fun getValue(thisRef: T, desc: KProperty<*>): String {
println("get $thisRef ${desc.name}")
return ""
}
operator fun setValue(thisRef: Any?, desc: PropertyMetadata, value: T) {
operator fun setValue(thisRef: Any?, desc: KProperty<*>, value: T) {
println("set $thisRef ${desc.name} $value")
}
}
//--------------------------
fun println(a: Any?) = a
fun println(a: Any?) = a
@@ -42,27 +42,27 @@ package foo {
public final class MyProperty1</*0*/ R, /*1*/ T> {
public constructor MyProperty1</*0*/ R, /*1*/ T>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.PropertyMetadata): T
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.PropertyMetadata, /*2*/ value: T): kotlin.Unit
public final operator fun setValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.reflect.KProperty<*>, /*2*/ value: T): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
public final class MyProperty2</*0*/ T> {
public constructor MyProperty2</*0*/ T>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.PropertyMetadata): T
public final operator fun getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.PropertyMetadata, /*2*/ value: T): kotlin.Unit
public final operator fun setValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.reflect.KProperty<*>, /*2*/ value: T): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
public final class MyProperty3</*0*/ T> {
public constructor MyProperty3</*0*/ T>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: T, /*1*/ desc: kotlin.PropertyMetadata): kotlin.String
public final operator fun getValue(/*0*/ thisRef: T, /*1*/ desc: kotlin.reflect.KProperty<*>): kotlin.String
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.PropertyMetadata, /*2*/ value: T): kotlin.Unit
public final operator fun setValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.reflect.KProperty<*>, /*2*/ value: T): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
}
@@ -1,5 +1,7 @@
package foo
import kotlin.reflect.KProperty
class A1 {
val a1: String by MyProperty1()
val b1: String by getMyProperty1()
@@ -12,7 +14,7 @@ fun <A, B> getMyProperty1() = MyProperty1<A, B>()
class MyProperty1<R, T> {
operator fun getValue(thisRef: R, desc: PropertyMetadata): T {
operator fun getValue(thisRef: R, desc: KProperty<*>): T {
println("get $thisRef ${desc.name}")
throw Exception()
}
@@ -32,7 +34,7 @@ fun <A> getMyProperty2() = MyProperty2<A>()
class MyProperty2<T> {
operator fun getValue(thisRef: Any?, desc: PropertyMetadata): T {
operator fun getValue(thisRef: Any?, desc: KProperty<*>): T {
println("get $thisRef ${desc.name}")
throw Exception()
}
@@ -52,11 +54,11 @@ fun <A> getMyProperty3() = MyProperty3<A>()
class MyProperty3<T> {
operator fun getValue(thisRef: T, desc: PropertyMetadata): String {
operator fun getValue(thisRef: T, desc: KProperty<*>): String {
println("get $thisRef ${desc.name}")
return ""
}
}
//--------------------------
fun println(a: Any?) = a
fun println(a: Any?) = a
@@ -42,7 +42,7 @@ package foo {
public final class MyProperty1</*0*/ R, /*1*/ T> {
public constructor MyProperty1</*0*/ R, /*1*/ T>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.PropertyMetadata): T
public final operator fun getValue(/*0*/ thisRef: R, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -50,7 +50,7 @@ package foo {
public final class MyProperty2</*0*/ T> {
public constructor MyProperty2</*0*/ T>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.PropertyMetadata): T
public final operator fun getValue(/*0*/ thisRef: kotlin.Any?, /*1*/ desc: kotlin.reflect.KProperty<*>): T
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -58,7 +58,7 @@ package foo {
public final class MyProperty3</*0*/ T> {
public constructor MyProperty3</*0*/ T>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ thisRef: T, /*1*/ desc: kotlin.PropertyMetadata): kotlin.String
public final operator fun getValue(/*0*/ thisRef: T, /*1*/ desc: kotlin.reflect.KProperty<*>): kotlin.String
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER -UNUSED_VARIABLE
import kotlin.reflect.KProperty
class Local {
fun foo() {
val a: Int <!LOCAL_VARIABLE_WITH_DELEGATE!>by Delegate()<!>
@@ -7,7 +9,7 @@ class Local {
}
class Delegate {
fun getValue(t: Any?, p: PropertyMetadata): Int {
fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
@@ -3,7 +3,7 @@ package
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,3 +1,3 @@
val a: Int by <!DELEGATE_SPECIAL_FUNCTION_MISSING(getValue\(kotlin.Nothing?, kotlin.PropertyMetadata\); A)!>A()<!>
val a: Int by <!DELEGATE_SPECIAL_FUNCTION_MISSING(getValue\(kotlin.Nothing?, kotlin.reflect.KProperty<*>\); A)!>A()<!>
class A
@@ -1,9 +1,11 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
var a: Int by <!DELEGATE_SPECIAL_FUNCTION_MISSING(setValue\(kotlin.Nothing?, kotlin.PropertyMetadata, kotlin.Int\); A)!>A()<!>
import kotlin.reflect.KProperty
var a: Int by <!DELEGATE_SPECIAL_FUNCTION_MISSING(setValue\(kotlin.Nothing?, kotlin.reflect.KProperty<*>, kotlin.Int\); A)!>A()<!>
class A {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
@@ -5,7 +5,7 @@ public var a: kotlin.Int
public final class A {
public constructor A()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,9 +1,11 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class B {
val c by Delegate(<!UNRESOLVED_REFERENCE!>ag<!>)
}
class Delegate<T: Any>(val init: T) {
operator fun getValue(t: Any?, p: PropertyMetadata): Int = null!!
operator fun getValue(t: Any?, p: KProperty<*>): Int = null!!
}
@@ -12,7 +12,7 @@ public final class Delegate</*0*/ T : kotlin.Any> {
public constructor Delegate</*0*/ T : kotlin.Any>(/*0*/ init: T)
public final val init: T
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,13 +1,15 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val a: Int by <!DELEGATE_SPECIAL_FUNCTION_AMBIGUITY!>Delegate()<!>
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
fun propertyDelegated(p: PropertyMetadata, i: Int = 1) {}
fun propertyDelegated(p: KProperty<*>, i: Int = 1) {}
fun propertyDelegated(p: PropertyMetadata, s: String = "") {}
}
fun propertyDelegated(p: KProperty<*>, s: String = "") {}
}
@@ -5,9 +5,9 @@ public val a: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final fun propertyDelegated(/*0*/ p: kotlin.PropertyMetadata, /*1*/ i: kotlin.Int = ...): kotlin.Unit
public final fun propertyDelegated(/*0*/ p: kotlin.PropertyMetadata, /*1*/ s: kotlin.String = ...): kotlin.Unit
public final fun propertyDelegated(/*0*/ p: kotlin.reflect.KProperty<*>, /*1*/ i: kotlin.Int = ...): kotlin.Unit
public final fun propertyDelegated(/*0*/ p: kotlin.reflect.KProperty<*>, /*1*/ s: kotlin.String = ...): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,11 +1,13 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val a: Int by <!DELEGATE_PD_METHOD_NONE_APPLICABLE!>Delegate()<!>
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
fun <T> propertyDelegated(p: PropertyMetadata) {}
fun <T> propertyDelegated(p: KProperty<*>) {}
}
@@ -5,8 +5,8 @@ public val a: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final fun </*0*/ T> propertyDelegated(/*0*/ p: kotlin.PropertyMetadata): kotlin.Unit
public final fun </*0*/ T> propertyDelegated(/*0*/ p: kotlin.reflect.KProperty<*>): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,9 +1,11 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val a: Int by Delegate()
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
@@ -5,7 +5,7 @@ public val a: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,11 +1,13 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val a: Int by <!DELEGATE_PD_METHOD_NONE_APPLICABLE!>Delegate()<!>
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
private fun propertyDelegated(p: PropertyMetadata) {}
private fun propertyDelegated(p: KProperty<*>) {}
}
@@ -5,8 +5,8 @@ public val a: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
private final fun propertyDelegated(/*0*/ p: kotlin.PropertyMetadata): kotlin.Unit
private final fun propertyDelegated(/*0*/ p: kotlin.reflect.KProperty<*>): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,9 +1,11 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val a: Int by <!DELEGATE_PD_METHOD_NONE_APPLICABLE!>Delegate()<!>
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
@@ -13,5 +15,5 @@ class Delegate {
fun propertyDelegated(a: String) {}
fun propertyDelegated(p: PropertyMetadata, a: Int) {}
fun propertyDelegated(p: KProperty<*>, a: Int) {}
}
@@ -5,11 +5,11 @@ public val a: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final fun propertyDelegated(): kotlin.Unit
public final fun propertyDelegated(/*0*/ a: kotlin.Int): kotlin.Unit
public final fun propertyDelegated(/*0*/ p: kotlin.PropertyMetadata, /*1*/ a: kotlin.Int): kotlin.Unit
public final fun propertyDelegated(/*0*/ a: kotlin.String): kotlin.Unit
public final fun propertyDelegated(/*0*/ p: kotlin.reflect.KProperty<*>, /*1*/ a: kotlin.Int): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val a by <!TYPECHECKER_HAS_RUN_INTO_RECURSIVE_PROBLEM!>a<!>
val b by Delegate(<!TYPECHECKER_HAS_RUN_INTO_RECURSIVE_PROBLEM!>b<!>)
@@ -8,7 +10,7 @@ val c by <!DEBUG_INFO_ELEMENT_WITH_ERROR_TYPE!>d<!>
val d by <!TYPECHECKER_HAS_RUN_INTO_RECURSIVE_PROBLEM!>c<!>
class Delegate(i: Int) {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
}
@@ -8,7 +8,7 @@ public val d: [ERROR : <ERROR FUNCTION RETURN TYPE>]
public final class Delegate {
public constructor Delegate(/*0*/ i: kotlin.Int)
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,10 +1,12 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val a: Int by Delegate()
<!ACCESSOR_FOR_DELEGATED_PROPERTY!>get() = 1<!>
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
}
@@ -5,7 +5,7 @@ public val a: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,13 +1,15 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
var a: Int by Delegate()
<!ACCESSOR_FOR_DELEGATED_PROPERTY!>get() = 1<!>
<!ACCESSOR_FOR_DELEGATED_PROPERTY!>set(i) {}<!>
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
operator fun setValue(t: Any?, p: PropertyMetadata, i: Int) {}
operator fun setValue(t: Any?, p: KProperty<*>, i: Int) {}
}
@@ -5,8 +5,8 @@ public var a: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ i: kotlin.Int): kotlin.Unit
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ i: kotlin.Int): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class D {
var c: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
}
@@ -9,8 +11,8 @@ var cTopLevel: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
class A
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
operator fun setValue(t: A, p: PropertyMetadata, i: Int) {}
operator fun setValue(t: A, p: KProperty<*>, i: Int) {}
}
@@ -20,8 +20,8 @@ public final class D {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ t: A, /*1*/ p: kotlin.PropertyMetadata, /*2*/ i: kotlin.Int): kotlin.Unit
public final operator fun setValue(/*0*/ t: A, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ i: kotlin.Int): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,15 +1,16 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
open class Base
class Derived: Base()
var a: Derived by A()
class A {
operator fun getValue(t: Any?, p: PropertyMetadata): Derived {
operator fun getValue(t: Any?, p: KProperty<*>): Derived {
return Derived()
}
operator fun setValue(t: Any?, p: PropertyMetadata, i: Base) {}
operator fun setValue(t: Any?, p: KProperty<*>, i: Base) {}
}
@@ -5,9 +5,9 @@ public var a: Derived
public final class A {
public constructor A()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): Derived
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): Derived
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ i: Base): kotlin.Unit
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ i: Base): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val Int.a by Delegate(<!NO_THIS!>this<!>)
class A {
@@ -7,7 +9,7 @@ class A {
}
class Delegate(i: Int) {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
}
}
@@ -13,7 +13,7 @@ public final class A {
public final class Delegate {
public constructor Delegate(/*0*/ i: kotlin.Int)
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class A {
var a: Int by Delegate()
}
@@ -7,8 +9,8 @@ class A {
var aTopLevel: Int by Delegate()
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
operator fun setValue(t: Any?, p: PropertyMetadata, a: Int) {}
}
operator fun setValue(t: Any?, p: KProperty<*>, a: Int) {}
}
@@ -13,8 +13,8 @@ public final class A {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ a: kotlin.Int): kotlin.Unit
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ a: kotlin.Int): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,3 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class A {
var a: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE, DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
}
@@ -5,11 +9,9 @@ class A {
var aTopLevel: Int by Delegate()
class Delegate {
operator fun getValue(t: Nothing?, p: PropertyMetadata): Int {
p.equals(null) // to avoid UNUSED_PARAMETER warning
operator fun getValue(t: Nothing?, p: KProperty<*>): Int {
return 1
}
operator fun setValue(t: Nothing?, p: PropertyMetadata, a: Int) {
p.equals(a) // to avoid UNUSED_PARAMETER warning
operator fun setValue(t: Nothing?, p: KProperty<*>, a: Int) {
}
}
}
@@ -13,8 +13,8 @@ public final class A {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Nothing?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Nothing?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ t: kotlin.Nothing?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ a: kotlin.Int): kotlin.Unit
public final operator fun setValue(/*0*/ t: kotlin.Nothing?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ a: kotlin.Int): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,3 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class A {
var a: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE, DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
}
@@ -5,11 +9,9 @@ class A {
var aTopLevel: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE, DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
class Delegate {
fun getValue(t: Nothing, p: PropertyMetadata): Int {
p.equals(null) // to avoid UNUSED_PARAMETER warning
fun getValue(t: Nothing, p: KProperty<*>): Int {
return 1
}
fun setValue(t: Nothing, p: PropertyMetadata, a: Int) {
p.equals(a) // to avoid UNUSED_PARAMETER warning
fun setValue(t: Nothing, p: KProperty<*>, a: Int) {
}
}
}
@@ -13,8 +13,8 @@ public final class A {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final fun getValue(/*0*/ t: kotlin.Nothing, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final fun getValue(/*0*/ t: kotlin.Nothing, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final fun setValue(/*0*/ t: kotlin.Nothing, /*1*/ p: kotlin.PropertyMetadata, /*2*/ a: kotlin.Int): kotlin.Unit
public final fun setValue(/*0*/ t: kotlin.Nothing, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ a: kotlin.Int): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,15 +1,17 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class A {
val c: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
}
class Delegate {
fun getValue(t: Int, p: PropertyMetadata): Int {
t.equals(p) // to avoid UNUSED_PARAMETER warning
fun getValue(t: Int, p: KProperty<*>): Int {
return 1
}
fun getValue(t: String, p: PropertyMetadata): Int {
t.equals(p) // to avoid UNUSED_PARAMETER warning
fun getValue(t: String, p: KProperty<*>): Int {
return 1
}
}
@@ -11,8 +11,8 @@ public final class A {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final fun getValue(/*0*/ t: kotlin.Int, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final fun getValue(/*0*/ t: kotlin.String, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final fun getValue(/*0*/ t: kotlin.Int, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public final fun getValue(/*0*/ t: kotlin.String, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,9 +1,11 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
val c: Int by <!DELEGATE_SPECIAL_FUNCTION_RETURN_TYPE_MISMATCH!>Delegate()<!>
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): String {
operator fun getValue(t: Any?, p: KProperty<*>): String {
return ""
}
}
@@ -5,7 +5,7 @@ public val c: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.String
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.String
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,4 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class A
class B {
@@ -14,7 +17,7 @@ class C {
val cTopLevel: Int by Delegate<Nothing?>()
class Delegate<T> {
operator fun getValue(t: T, p: PropertyMetadata): Int {
operator fun getValue(t: T, p: KProperty<*>): Int {
return 1
}
}
}
@@ -29,7 +29,7 @@ public final class C {
public final class Delegate</*0*/ T> {
public constructor Delegate</*0*/ T>()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: T, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: T, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class A {
var a: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
}
@@ -7,8 +9,8 @@ class A {
var aTopLevel: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
operator fun setValue(t: Any?, p: PropertyMetadata, i: String) {}
operator fun setValue(t: Any?, p: KProperty<*>, i: String) {}
}
@@ -13,8 +13,8 @@ public final class A {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ i: kotlin.String): kotlin.Unit
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ i: kotlin.String): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,3 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class B {
val b: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
}
@@ -7,9 +11,7 @@ val bTopLevel: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
class A
class Delegate {
fun getValue(t: A, p: PropertyMetadata): Int {
t.equals(p) // to avoid UNUSED_PARAMETER warning
fun getValue(t: A, p: KProperty<*>): Int {
return 1
}
}
@@ -20,7 +20,7 @@ public final class B {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final fun getValue(/*0*/ t: A, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final fun getValue(/*0*/ t: A, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class A {
val a: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
}
@@ -7,7 +9,7 @@ class A {
val aTopLevel: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
class Delegate {
fun getValue(t: Any?, p: PropertyMetadata, a: Int): Int {
fun getValue(t: Any?, p: KProperty<*>, a: Int): Int {
return a
}
}
@@ -13,7 +13,7 @@ public final class A {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ a: kotlin.Int): kotlin.Int
public final fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ a: kotlin.Int): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,5 +1,7 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
class A {
var a: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
}
@@ -7,9 +9,9 @@ class A {
var aTopLevel: Int by <!DELEGATE_SPECIAL_FUNCTION_NONE_APPLICABLE!>Delegate()<!>
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
operator fun setValue(t: Any?, p: PropertyMetadata, a: Int, c: Int) {}
}
operator fun setValue(t: Any?, p: KProperty<*>, a: Int, c: Int) {}
}
@@ -13,8 +13,8 @@ public final class A {
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ a: kotlin.Int, /*3*/ c: kotlin.Int): kotlin.Unit
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ a: kotlin.Int, /*3*/ c: kotlin.Int): kotlin.Unit
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}
@@ -1,13 +1,15 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
import kotlin.reflect.KProperty
var b: Int by Delegate()
class Delegate {
operator fun getValue(t: Any?, p: PropertyMetadata): Int {
operator fun getValue(t: Any?, p: KProperty<*>): Int {
return 1
}
operator fun setValue(t: Any?, p: PropertyMetadata, i: Int): Int {
operator fun setValue(t: Any?, p: KProperty<*>, i: Int): Int {
return i
}
}
}
@@ -5,8 +5,8 @@ public var b: kotlin.Int
public final class Delegate {
public constructor Delegate()
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata): kotlin.Int
public final operator fun getValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>): kotlin.Int
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.PropertyMetadata, /*2*/ i: kotlin.Int): kotlin.Int
public final operator fun setValue(/*0*/ t: kotlin.Any?, /*1*/ p: kotlin.reflect.KProperty<*>, /*2*/ i: kotlin.Int): kotlin.Int
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String
}