b44dc55109
There was a refactoring of AbstractDiagnosticsTest in 9052ef06 which
contains bug that `setupEnvironment` for AbstractDiagnosticsTestUsingJavac
was not called, so for last year tests `UsingJavac` had no difference
with usual diagnostics tests which causes some contradictions in test data
35 lines
713 B
Kotlin
Vendored
35 lines
713 B
Kotlin
Vendored
// !SKIP_JAVAC
|
|
// !LANGUAGE: +InlineClasses
|
|
|
|
package kotlin.jvm
|
|
|
|
annotation class JvmInline
|
|
|
|
class Val {
|
|
operator fun getValue(thisRef: Any?, kProp: Any?) = 1
|
|
}
|
|
|
|
class Var {
|
|
operator fun getValue(thisRef: Any?, kProp: Any?) = 2
|
|
operator fun setValue(thisRef: Any?, kProp: Any?, value: Int) {}
|
|
}
|
|
|
|
|
|
object ValObject {
|
|
operator fun getValue(thisRef: Any?, kProp: Any?) = 1
|
|
}
|
|
|
|
object VarObject {
|
|
operator fun getValue(thisRef: Any?, kProp: Any?) = 2
|
|
operator fun setValue(thisRef: Any?, kProp: Any?, value: Int) {}
|
|
}
|
|
|
|
@JvmInline
|
|
value class Z(val data: Int) {
|
|
val testVal by Val()
|
|
var testVar by Var()
|
|
|
|
val testValBySingleton by ValObject
|
|
var testVarBySingleton by VarObject
|
|
}
|