[IR] update testdata: super and receiver for field accesses
This commit is contained in:
committed by
teamcityserver
parent
029ee6f2e7
commit
a6b408978f
@@ -11,14 +11,14 @@ fun test2(mc: MutableCollection<String>) {
|
||||
|
||||
fun test3() {
|
||||
{ // BLOCK
|
||||
val tmp0_safe_receiver: @FlexibleNullability PrintStream? = #out
|
||||
val tmp0_safe_receiver: @FlexibleNullability PrintStream? = super.#out
|
||||
when {
|
||||
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
|
||||
true -> tmp0_safe_receiver /*!! PrintStream */.println(p0 = "Hello,")
|
||||
}
|
||||
} /*~> Unit */
|
||||
{ // BLOCK
|
||||
val tmp1_safe_receiver: @FlexibleNullability PrintStream? = #out
|
||||
val tmp1_safe_receiver: @FlexibleNullability PrintStream? = super.#out
|
||||
when {
|
||||
EQEQ(arg0 = tmp1_safe_receiver, arg1 = null) -> null
|
||||
true -> tmp1_safe_receiver /*!! PrintStream */.println(p0 = "world!")
|
||||
|
||||
+2
-2
@@ -7,10 +7,10 @@ fun testEquals(a: Int, b: Int): Boolean {
|
||||
}
|
||||
|
||||
fun testJEqeqNull(): Boolean {
|
||||
return EQEQ(arg0 = #INT_NULL, arg1 = null)
|
||||
return EQEQ(arg0 = super.#INT_NULL, arg1 = null)
|
||||
}
|
||||
|
||||
fun testJEqualsNull(): Boolean {
|
||||
return #INT_NULL /*!! Int */.equals(other = null)
|
||||
return super.#INT_NULL /*!! Int */.equals(other = null)
|
||||
}
|
||||
|
||||
|
||||
+4
-4
@@ -54,15 +54,15 @@ fun test(b: Boolean) {
|
||||
b -> d1
|
||||
true -> d2
|
||||
}
|
||||
#f = 42
|
||||
#f /*~> Unit */
|
||||
k /*as JFieldOwner */super.#f = 42
|
||||
k /*as JFieldOwner */super.#f /*~> Unit */
|
||||
val md1: DerivedThroughMid1 = DerivedThroughMid1()
|
||||
val md2: DerivedThroughMid2 = DerivedThroughMid2()
|
||||
val mk: Any = when {
|
||||
b -> md1
|
||||
true -> md2
|
||||
}
|
||||
#f = 44
|
||||
#f /*~> Unit */
|
||||
mk /*as Mid */super.#f = 44
|
||||
mk /*as Mid */super.#f /*~> Unit */
|
||||
}
|
||||
|
||||
|
||||
@@ -6,15 +6,15 @@ class Derived : Base {
|
||||
}
|
||||
|
||||
init {
|
||||
#value = 0
|
||||
<this>super.#value = 0
|
||||
}
|
||||
|
||||
fun getValue(): Int {
|
||||
return #value
|
||||
return <this>super.#value
|
||||
}
|
||||
|
||||
fun setValue(value: Int) {
|
||||
#value = value
|
||||
<this>super.#value = value
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
fun testFun() {
|
||||
#out /*!! PrintStream */.println(p0 = "testFun")
|
||||
super.#out /*!! PrintStream */.println(p0 = "testFun")
|
||||
}
|
||||
|
||||
var testProp: Any
|
||||
get(): Any {
|
||||
#out /*!! PrintStream */.println(p0 = "testProp/get")
|
||||
super.#out /*!! PrintStream */.println(p0 = "testProp/get")
|
||||
return 42
|
||||
}
|
||||
set(value: Any) {
|
||||
#out /*!! PrintStream */.println(p0 = "testProp/set")
|
||||
super.#out /*!! PrintStream */.println(p0 = "testProp/set")
|
||||
}
|
||||
|
||||
class TestClass {
|
||||
@@ -21,14 +21,14 @@ class TestClass {
|
||||
val test: Int
|
||||
field = when {
|
||||
true -> { // BLOCK
|
||||
#out /*!! PrintStream */.println(p0 = "TestClass/test")
|
||||
super.#out /*!! PrintStream */.println(p0 = "TestClass/test")
|
||||
42
|
||||
}
|
||||
}
|
||||
get
|
||||
|
||||
init {
|
||||
#out /*!! PrintStream */.println(p0 = "TestClass/init")
|
||||
super.#out /*!! PrintStream */.println(p0 = "TestClass/init")
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
+1
-1
@@ -53,7 +53,7 @@ class Test2 : J {
|
||||
}
|
||||
|
||||
init {
|
||||
#field = 42
|
||||
<this>super.#field = 42
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
+1
-1
@@ -14,7 +14,7 @@ class A {
|
||||
|
||||
init {
|
||||
a().apply<String>(block = local fun String.<anonymous>() {
|
||||
#b = <this>
|
||||
<this>.#b = <this>
|
||||
}
|
||||
) /*~> Unit */
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@ class Derived : Base {
|
||||
fun setValue(v: Any) {
|
||||
when {
|
||||
v is String -> { // BLOCK
|
||||
#value = v /*as String */
|
||||
<this>super.#value = v /*as String */
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@ class C {
|
||||
get
|
||||
|
||||
init {
|
||||
#s = { // BLOCK
|
||||
<this>.#s = { // BLOCK
|
||||
val tmp0_safe_receiver: Any? = x
|
||||
when {
|
||||
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
|
||||
|
||||
Reference in New Issue
Block a user