[IR] update testdata: support IrDynamic* nodes
This commit is contained in:
committed by
teamcityserver
parent
82839e6a67
commit
635cb44bf3
@@ -1,15 +1,12 @@
|
||||
fun testArrayAccess1(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d["KEY"]
|
||||
}
|
||||
|
||||
fun testArrayAccess2(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d()["KEY"]
|
||||
}
|
||||
|
||||
fun testArrayAccess3(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d.get("KEY")
|
||||
}
|
||||
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
fun testArrayAssignment(d: dynamic) {
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
d["KEY"] = 1
|
||||
}
|
||||
|
||||
fun testArrayAssignmentFake(d: dynamic) {
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
d.set("KEY", 2)
|
||||
}
|
||||
|
||||
|
||||
+5
-10
@@ -1,13 +1,8 @@
|
||||
fun testArrayAugmentedAssignment(d: dynamic) {
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
d["KEY"] += "+="
|
||||
d["KEY"] -= "-="
|
||||
d["KEY"] *= "*="
|
||||
d["KEY"] /= "/="
|
||||
d["KEY"] %= "%="
|
||||
}
|
||||
|
||||
|
||||
+4
-8
@@ -1,11 +1,7 @@
|
||||
fun testArrayIncrementDecrement(d: dynamic) {
|
||||
val t1: dynamic = error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
val t2: dynamic = error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
val t3: dynamic = error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
val t4: dynamic = error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
val t1: dynamic = ++d["prefixIncr"]
|
||||
val t2: dynamic = --d["prefixDecr"]
|
||||
val t3: dynamic = d["postfixIncr"]++
|
||||
val t4: dynamic = d["postfixDecr"]--
|
||||
}
|
||||
|
||||
|
||||
@@ -1,20 +1,16 @@
|
||||
fun testEqeq(d: dynamic): Boolean {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d == 3
|
||||
}
|
||||
|
||||
fun testExclEq(d: dynamic): Boolean {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d != 3
|
||||
}
|
||||
|
||||
fun testEqeqeq(d: dynamic): Boolean {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d === 3
|
||||
}
|
||||
|
||||
fun testExclEqeq(d: dynamic): Boolean {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d !== 3
|
||||
}
|
||||
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
fun testAndAnd(d: dynamic): Boolean {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d && d
|
||||
}
|
||||
|
||||
fun testOrOr(d: dynamic): Boolean {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d || d
|
||||
}
|
||||
|
||||
|
||||
@@ -1,25 +1,20 @@
|
||||
fun testBinaryPlus(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d + 1
|
||||
}
|
||||
|
||||
fun testBinaryMinus(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d - 1
|
||||
}
|
||||
|
||||
fun testMul(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d * 2
|
||||
}
|
||||
|
||||
fun testDiv(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d / 2
|
||||
}
|
||||
|
||||
fun testMod(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d % 2
|
||||
}
|
||||
|
||||
|
||||
+4
-8
@@ -1,20 +1,16 @@
|
||||
fun testLess(d: dynamic): Boolean {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d < 2
|
||||
}
|
||||
|
||||
fun testLessOrEqual(d: dynamic): Boolean {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d <= 2
|
||||
}
|
||||
|
||||
fun testGreater(d: dynamic): Boolean {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d > 2
|
||||
}
|
||||
|
||||
fun testGreaterOrEqual(d: dynamic): Boolean {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d >= 2
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
fun test1(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d.member(1, 2, 3)
|
||||
}
|
||||
|
||||
fun test2(d: dynamic): dynamic {
|
||||
@@ -8,14 +7,12 @@ fun test2(d: dynamic): dynamic {
|
||||
val tmp0_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
true -> tmp0_safe_receiver.member(1, 2, 3)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun test3(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d.member(1, 2, 3)
|
||||
}
|
||||
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
fun test1(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d.foo(123)
|
||||
}
|
||||
|
||||
fun test2(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return d.invoke(123)
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
fun test1(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicMemberExpressionImpl */
|
||||
|
||||
return d.member
|
||||
}
|
||||
|
||||
fun test2(d: dynamic): dynamic {
|
||||
@@ -8,8 +7,7 @@ fun test2(d: dynamic): dynamic {
|
||||
val tmp0_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicMemberExpressionImpl */
|
||||
|
||||
true -> tmp0_safe_receiver.member
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
fun testMemberAssignment(d: dynamic) {
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
d.m = 1
|
||||
}
|
||||
|
||||
fun testSafeMemberAssignment(d: dynamic) {
|
||||
@@ -8,8 +7,7 @@ fun testSafeMemberAssignment(d: dynamic) {
|
||||
val tmp0_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null /*~> Unit */
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
true -> tmp0_safe_receiver.m = 1
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+10
-20
@@ -1,14 +1,9 @@
|
||||
fun testAugmentedMemberAssignment(d: dynamic) {
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
d.m += "+="
|
||||
d.m -= "-="
|
||||
d.m *= "*="
|
||||
d.m /= "/="
|
||||
d.m %= "%="
|
||||
}
|
||||
|
||||
fun testSafeAugmentedMemberAssignment(d: dynamic) {
|
||||
@@ -16,40 +11,35 @@ fun testSafeAugmentedMemberAssignment(d: dynamic) {
|
||||
val tmp0_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null /*~> Unit */
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
true -> tmp0_safe_receiver.m += "+="
|
||||
}
|
||||
}
|
||||
{ // BLOCK
|
||||
val tmp1_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp1_safe_receiver, arg1 = null) -> null /*~> Unit */
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
true -> tmp1_safe_receiver.m -= "-="
|
||||
}
|
||||
}
|
||||
{ // BLOCK
|
||||
val tmp2_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp2_safe_receiver, arg1 = null) -> null /*~> Unit */
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
true -> tmp2_safe_receiver.m *= "*="
|
||||
}
|
||||
}
|
||||
{ // BLOCK
|
||||
val tmp3_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp3_safe_receiver, arg1 = null) -> null /*~> Unit */
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
true -> tmp3_safe_receiver.m /= "/="
|
||||
}
|
||||
}
|
||||
{ // BLOCK
|
||||
val tmp4_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp4_safe_receiver, arg1 = null) -> null /*~> Unit */
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
true -> tmp4_safe_receiver.m %= "%="
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+8
-16
@@ -1,12 +1,8 @@
|
||||
fun testMemberIncrementDecrement(d: dynamic) {
|
||||
val t1: dynamic = error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
val t2: dynamic = error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
val t3: dynamic = error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
val t4: dynamic = error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
val t1: dynamic = ++d.prefixIncr
|
||||
val t2: dynamic = --d.prefixDecr
|
||||
val t3: dynamic = d.postfixIncr++
|
||||
val t4: dynamic = d.postfixDecr--
|
||||
}
|
||||
|
||||
fun testSafeMemberIncrementDecrement(d: dynamic) {
|
||||
@@ -14,32 +10,28 @@ fun testSafeMemberIncrementDecrement(d: dynamic) {
|
||||
val tmp0_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
true -> ++tmp0_safe_receiver.prefixIncr
|
||||
}
|
||||
}
|
||||
val t2: dynamic = { // BLOCK
|
||||
val tmp1_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp1_safe_receiver, arg1 = null) -> null
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
true -> --tmp1_safe_receiver.prefixDecr
|
||||
}
|
||||
}
|
||||
val t3: dynamic = { // BLOCK
|
||||
val tmp2_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp2_safe_receiver, arg1 = null) -> null
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
true -> tmp2_safe_receiver.postfixIncr++
|
||||
}
|
||||
}
|
||||
val t4: dynamic = { // BLOCK
|
||||
val tmp3_safe_receiver: dynamic = d
|
||||
when {
|
||||
EQEQ(arg0 = tmp3_safe_receiver, arg1 = null) -> null
|
||||
true -> error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
true -> tmp3_safe_receiver.postfixDecr--
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,15 +1,12 @@
|
||||
fun testUnaryMinus(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return -d
|
||||
}
|
||||
|
||||
fun testUnaryPlus(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return +d
|
||||
}
|
||||
|
||||
fun testExcl(d: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return !d
|
||||
}
|
||||
|
||||
|
||||
@@ -19,7 +19,6 @@ fun test3(d: dynamic): Any? {
|
||||
}
|
||||
|
||||
fun test4(d: dynamic): String {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
/*~> String */
|
||||
return d.member(1, 2, 3) /*~> String */
|
||||
}
|
||||
|
||||
|
||||
+6
-12
@@ -2,33 +2,27 @@ fun invoke() {
|
||||
}
|
||||
|
||||
fun test1(a: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return a(1)
|
||||
}
|
||||
|
||||
fun test2(a: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return a.invoke(1)
|
||||
}
|
||||
|
||||
fun test3(a: dynamic, b: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return a(b)
|
||||
}
|
||||
|
||||
fun test4(a: dynamic, b: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return a.invoke(b)
|
||||
}
|
||||
|
||||
fun test5(a: dynamic, b: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return a(b)(b)
|
||||
}
|
||||
|
||||
fun test6(a: dynamic, b: dynamic): dynamic {
|
||||
return error("") /* ERROR: unsupported element type: IrDynamicOperatorExpressionImpl */
|
||||
|
||||
return a(b).invoke(b)
|
||||
}
|
||||
|
||||
fun test7(a: dynamic) {
|
||||
|
||||
Reference in New Issue
Block a user