[IR] update testdata

This commit is contained in:
Zalim Bashorov
2020-11-05 23:40:21 +03:00
committed by teamcityserver
parent 6a1ab1b325
commit fc5c674c60
94 changed files with 354 additions and 354 deletions
@@ -20,7 +20,7 @@ open class Base {
class Test1 : Base {
constructor(xx: Int, yy: Int) /* primary */ {
{ //BLOCK
{ // BLOCK
TODO("IrDelegatingConstructorCall")
}
/* InstanceInitializerCall */
@@ -34,7 +34,7 @@ class Test1 : Base {
class Test2 : Base {
constructor(xx: Int, yy: Int) {
{ //BLOCK
{ // BLOCK
TODO("IrDelegatingConstructorCall")
}
/* InstanceInitializerCall */
@@ -42,7 +42,7 @@ class Test2 : Base {
}
constructor(xxx: Int, yyy: Int, a: Any) {
{ //BLOCK
{ // BLOCK
TODO("IrDelegatingConstructorCall")
}
}
@@ -50,7 +50,7 @@ interface IOther {
}
fun otherImpl(x0: String, y0: Int): IOther {
return { //BLOCK
return { // BLOCK
local class <no name provided> : IOther {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
+1 -1
View File
@@ -131,7 +131,7 @@ enum class TestEnum6 : Enum<TestEnum6> {
field = y
get
TEST init = { //BLOCK
TEST init = { // BLOCK
val tmp0_y: Int = f()
val tmp1_x: Int = f()
TODO("IrEnumConstructorCall")
@@ -48,7 +48,7 @@ data class A {
}
data class B {
constructor(x: Any = { //BLOCK
constructor(x: Any = { // BLOCK
local class <no name provided> {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -6,7 +6,7 @@ interface IFoo {
}
val test1: Any
field = { //BLOCK
field = { // BLOCK
local class <no name provided> {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -25,7 +25,7 @@ val test1: Any
get
val test2: IFoo
field = { //BLOCK
field = { // BLOCK
local class <no name provided> : IFoo {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -68,7 +68,7 @@ class Outer {
}
fun test3(): Inner {
return { //BLOCK
return { // BLOCK
local class <no name provided> : Inner {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -96,7 +96,7 @@ class Outer {
}
fun Outer.test4(): Inner {
return { //BLOCK
return { // BLOCK
local class <no name provided> : Inner {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -1,7 +1,7 @@
val test: Unit
field = try { //BLOCK
field = try { // BLOCK
}
catch (...) { //BLOCK
catch (...) { // BLOCK
}
get
@@ -24,7 +24,7 @@ fun test2() {
<set-x>(value = 0)
{ //BLOCK
{ // BLOCK
val tmp0: Int = <get-x>()
<set-x>(value = tmp0.inc())
tmp0
@@ -1,5 +1,5 @@
fun foo() {
{ //BLOCK
{ // BLOCK
do// COMPOSITE {
val x: Int = 42
// } while (EQEQ(arg0 = x, arg1 = 42).not())
@@ -10,10 +10,10 @@ fun f(f1: Function0<String> = local fun <anonymous>(): String {
fun box(): String {
var result: String = "fail"
try { //BLOCK
try { // BLOCK
f() /*~> Unit */
}
catch (...) { //BLOCK
catch (...) { // BLOCK
result = "OK"
}
+1 -1
View File
@@ -1,6 +1,6 @@
typealias Test1 = String
fun foo() {
{ //BLOCK
{ // BLOCK
}
}
@@ -24,7 +24,7 @@ class C {
fun testVariable() {
var x: IntArray = foo()
{ //BLOCK
{ // BLOCK
val tmp0_array: IntArray = x
val tmp1_index0: Int = 0
tmp0_array.set(index = tmp1_index0, value = tmp0_array.get(index = tmp1_index0).plus(other = 1))
@@ -32,7 +32,7 @@ fun testVariable() {
}
fun testCall() {
{ //BLOCK
{ // BLOCK
val tmp0_array: IntArray = foo()
val tmp1_index0: Int = bar()
tmp0_array.set(index = tmp1_index0, value = tmp0_array.get(index = tmp1_index0).times(other = 2))
@@ -40,7 +40,7 @@ fun testCall() {
}
fun testMember(c: C) {
{ //BLOCK
{ // BLOCK
val tmp0_array: IntArray = c.<get-x>()
val tmp1_index0: Int = 0
val tmp2: Int = tmp0_array.get(index = tmp1_index0)
@@ -13,7 +13,7 @@ interface IB {
}
fun IB.test(a: IA) {
{ //BLOCK
{ // BLOCK
val tmp0_array: IA = a
val tmp1_index0: String = ""
<this>.set($receiver = tmp0_array, index = tmp1_index0, value = tmp0_array.get(index = tmp1_index0).plus(other = 42))
@@ -13,19 +13,19 @@ fun testVariable() {
}
fun testProperty() {
{ //BLOCK
{ // BLOCK
<set-p>(<set-?> = <get-p>().plus(other = 1))
}
{ //BLOCK
{ // BLOCK
<set-p>(<set-?> = <get-p>().minus(other = 2))
}
{ //BLOCK
{ // BLOCK
<set-p>(<set-?> = <get-p>().times(other = 3))
}
{ //BLOCK
{ // BLOCK
<set-p>(<set-?> = <get-p>().div(other = 4))
}
{ //BLOCK
{ // BLOCK
<set-p>(<set-?> = <get-p>().rem(other = 5))
}
}
@@ -39,19 +39,19 @@ fun testVariable() {
}
fun testProperty() {
{ //BLOCK
{ // BLOCK
plusAssign($receiver = <get-p>(), s = "+=")
}
{ //BLOCK
{ // BLOCK
minusAssign($receiver = <get-p>(), s = "-=")
}
{ //BLOCK
{ // BLOCK
timesAssign($receiver = <get-p>(), s = "*=")
}
{ //BLOCK
{ // BLOCK
divAssign($receiver = <get-p>(), s = "/=")
}
{ //BLOCK
{ // BLOCK
remAssign($receiver = <get-p>(), s = "%=")
}
}
@@ -4,14 +4,14 @@ fun test1() {
}
fun test2() {
while (true) { //BLOCK
while (true) { // BLOCK
error("") /* ERROR EXPRESSION */
error("") /* ERROR EXPRESSION */
}
}
fun test3() {
while (true) { //BLOCK
while (true) { // BLOCK
val lambda: Function0<Nothing> = local fun <anonymous>(): Nothing {
error("") /* ERROR EXPRESSION */
error("") /* ERROR EXPRESSION */
@@ -21,9 +21,9 @@ fun test3() {
}
fun test4() {
while (error("") /* ERROR EXPRESSION */) { //BLOCK
while (error("") /* ERROR EXPRESSION */) { // BLOCK
}
while (error("") /* ERROR EXPRESSION */) { //BLOCK
while (error("") /* ERROR EXPRESSION */) { // BLOCK
}
}
+1 -1
View File
@@ -3,7 +3,7 @@ fun test1(a: Any?): Any {
}
fun test2(a: Any?): Int {
return CHECK_NOT_NULL<Int>(arg0 = { //BLOCK
return CHECK_NOT_NULL<Int>(arg0 = { // BLOCK
val tmp0_safe_receiver: Any? = a
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
+12 -12
View File
@@ -1,16 +1,16 @@
fun test1() {
while (true) { //BLOCK
while (true) { // BLOCK
break
}
{ //BLOCK
{ // BLOCK
do// COMPOSITE {
break
// } while (true)
}
while (true) { //BLOCK
while (true) { // BLOCK
continue
}
{ //BLOCK
{ // BLOCK
do// COMPOSITE {
continue
// } while (true)
@@ -18,15 +18,15 @@ fun test1() {
}
fun test2() {
while (true) { //BLOCK
while (true) { //BLOCK
while (true) { // BLOCK
while (true) { // BLOCK
break
break
}
break
}
while (true) { //BLOCK
while (true) { //BLOCK
while (true) { // BLOCK
while (true) { // BLOCK
continue
continue
}
@@ -35,14 +35,14 @@ fun test2() {
}
fun test3() {
while (true) { //BLOCK
while (true) { //BLOCK
while (true) { // BLOCK
while (true) { // BLOCK
break
}
break
}
while (true) { //BLOCK
while (true) { //BLOCK
while (true) { // BLOCK
while (true) { // BLOCK
continue
}
continue
@@ -1,6 +1,6 @@
fun test1(c: Boolean?) {
while (true) { //BLOCK
while ({ //BLOCK
while (true) { // BLOCK
while ({ // BLOCK
val tmp0_elvis_lhs: Boolean? = c
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> break
@@ -11,8 +11,8 @@ fun test1(c: Boolean?) {
}
fun test2(c: Boolean?) {
while (true) { //BLOCK
while ({ //BLOCK
while (true) { // BLOCK
while ({ // BLOCK
val tmp0_elvis_lhs: Boolean? = c
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> continue
@@ -23,16 +23,16 @@ fun test2(c: Boolean?) {
}
fun test3(ss: List<String>?) {
while (true) { //BLOCK
{ //BLOCK
val tmp1_iterator: Iterator<String> = { //BLOCK
while (true) { // BLOCK
{ // BLOCK
val tmp1_iterator: Iterator<String> = { // BLOCK
val tmp0_elvis_lhs: List<String>? = ss
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> continue
true -> tmp0_elvis_lhs
}
}.iterator()
while (tmp1_iterator.hasNext()) { //BLOCK
while (tmp1_iterator.hasNext()) { // BLOCK
val s: String = tmp1_iterator.next()
}
}
@@ -40,16 +40,16 @@ fun test3(ss: List<String>?) {
}
fun test4(ss: List<String>?) {
while (true) { //BLOCK
{ //BLOCK
val tmp1_iterator: Iterator<String> = { //BLOCK
while (true) { // BLOCK
{ // BLOCK
val tmp1_iterator: Iterator<String> = { // BLOCK
val tmp0_elvis_lhs: List<String>? = ss
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> break
true -> tmp0_elvis_lhs
}
}.iterator()
while (tmp1_iterator.hasNext()) { //BLOCK
while (tmp1_iterator.hasNext()) { // BLOCK
val s: String = tmp1_iterator.next()
}
}
@@ -58,15 +58,15 @@ fun test4(ss: List<String>?) {
fun test5() {
var i: Int = 0
while (true) { //BLOCK
{ //BLOCK
while (true) { // BLOCK
{ // BLOCK
i = i.inc()
i
} /*~> Unit */
var j: Int = 0
{ //BLOCK
{ // BLOCK
do// COMPOSITE {
{ //BLOCK
{ // BLOCK
j = j.inc()
j
} /*~> Unit */
@@ -1,11 +1,11 @@
fun testBreakFor() {
val xs: IntArray = TODO("IrConstructorCall")
var k: Int = 0
{ //BLOCK
{ // BLOCK
val tmp0_iterator: IntIterator = xs.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val x: Int = tmp0_iterator.next()
{ //BLOCK
{ // BLOCK
when {
greater(arg0 = k, arg1 = 2) -> break
}
@@ -16,7 +16,7 @@ fun testBreakFor() {
fun testBreakWhile() {
var k: Int = 0
while (less(arg0 = k, arg1 = 10)) { //BLOCK
while (less(arg0 = k, arg1 = 10)) { // BLOCK
when {
greater(arg0 = k, arg1 = 2) -> break
}
@@ -25,7 +25,7 @@ fun testBreakWhile() {
fun testBreakDoWhile() {
var k: Int = 0
{ //BLOCK
{ // BLOCK
do// COMPOSITE {
when {
greater(arg0 = k, arg1 = 2) -> break
@@ -37,11 +37,11 @@ fun testBreakDoWhile() {
fun testContinueFor() {
val xs: IntArray = TODO("IrConstructorCall")
var k: Int = 0
{ //BLOCK
{ // BLOCK
val tmp0_iterator: IntIterator = xs.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val x: Int = tmp0_iterator.next()
{ //BLOCK
{ // BLOCK
when {
greater(arg0 = k, arg1 = 2) -> continue
}
@@ -52,7 +52,7 @@ fun testContinueFor() {
fun testContinueWhile() {
var k: Int = 0
while (less(arg0 = k, arg1 = 10)) { //BLOCK
while (less(arg0 = k, arg1 = 10)) { // BLOCK
when {
greater(arg0 = k, arg1 = 2) -> continue
}
@@ -62,9 +62,9 @@ fun testContinueWhile() {
fun testContinueDoWhile() {
var k: Int = 0
var s: String = ""
{ //BLOCK
{ // BLOCK
do// COMPOSITE {
{ //BLOCK
{ // BLOCK
k = k.inc()
k
} /*~> Unit */
@@ -19,12 +19,12 @@ fun reordered2(): Int {
fun test() {
foo(a = noReorder1(), b = noReorder2())
{ //BLOCK
{ // BLOCK
val tmp0_b: Int = reordered1()
val tmp1_a: Int = reordered2()
foo(a = tmp1_a, b = tmp0_b)
}
{ //BLOCK
{ // BLOCK
val tmp2_a: Int = reordered2()
foo(a = tmp2_a, b = 1)
}
@@ -8,7 +8,7 @@ fun String.id(s: String = <this>, vararg xs: Int): String {
}
fun test() {
foo(x = { //BLOCK
foo(x = { // BLOCK
local fun String.id() {
id($receiver = receiver, ) /*~> Unit */
}
@@ -55,7 +55,7 @@ fun withVararg(vararg xs: Int): Int {
}
fun test1() {
{ //BLOCK
{ // BLOCK
val tmp0_array: A = A
val tmp2_sam: IFoo = local fun withVararg(p0: Int) {
withVararg(xs = [p0]) /*~> Unit */
@@ -66,7 +66,7 @@ fun test1() {
}
fun test2() {
{ //BLOCK
{ // BLOCK
val tmp0_array: B = B
val tmp2_sam: IFoo2 = local fun withVararg(p0: Int) {
withVararg(xs = [p0]) /*~> Unit */
@@ -77,7 +77,7 @@ fun test2() {
}
fun test3(fn: Function1<Int, Unit>) {
{ //BLOCK
{ // BLOCK
val tmp0_array: A = A
val tmp2_sam: IFoo = fn /*-> IFoo */
set($receiver = tmp0_array, i = tmp2_sam, newValue = get($receiver = tmp0_array, i = tmp2_sam).plus(other = 1))
@@ -86,8 +86,8 @@ fun test3(fn: Function1<Int, Unit>) {
fun test4(fn: Function1<Int, Unit>) {
when {
fn is IFoo -> { //BLOCK
{ //BLOCK
fn is IFoo -> { // BLOCK
{ // BLOCK
val tmp0_array: A = A
val tmp1_index0: Function1<Int, Unit> = fn
set($receiver = tmp0_array, i = tmp1_index0 /*as IFoo */, newValue = get($receiver = tmp0_array, i = tmp1_index0 /*as IFoo */).plus(other = 1))
@@ -98,7 +98,7 @@ fun test4(fn: Function1<Int, Unit>) {
fun test5(a: Any) {
a as Function1<Int, Unit> /*~> Unit */
{ //BLOCK
{ // BLOCK
val tmp0_array: A = A
val tmp2_sam: IFoo = a /*as Function1<@ParameterName(...) Int, Unit> */ /*-> IFoo */
set($receiver = tmp0_array, i = tmp2_sam, newValue = get($receiver = tmp0_array, i = tmp2_sam).plus(other = 1))
@@ -108,7 +108,7 @@ fun test5(a: Any) {
fun test6(a: Any) {
a as Function1<Int, Unit> /*~> Unit */
a as IFoo /*~> Unit */
{ //BLOCK
{ // BLOCK
val tmp0_array: A = A
val tmp1_index0: Any = a
set($receiver = tmp0_array, i = tmp1_index0 /*as IFoo */, newValue = get($receiver = tmp0_array, i = tmp1_index0 /*as IFoo */).plus(other = 1))
@@ -46,7 +46,7 @@ fun testConstructor(): Any {
}
fun testInnerClassConstructor(outer: Outer): Any {
return use(fn = { //BLOCK
return use(fn = { // BLOCK
local fun Outer.<init>(p0: Int): Inner {
return TODO("IrConstructorCall")
}
@@ -57,7 +57,7 @@ fun testInnerClassConstructor(outer: Outer): Any {
}
fun testInnerClassConstructorCapturingOuter(): Any {
return use(fn = { //BLOCK
return use(fn = { // BLOCK
local fun Outer.<init>(p0: Int): Inner {
return TODO("IrConstructorCall")
}
@@ -92,7 +92,7 @@ fun testWithDefaults() {
}
fun testWithBoundReceiver() {
useSuspend(fn = { //BLOCK
useSuspend(fn = { // BLOCK
local suspend fun C.bar() {
receiver.bar()
}
@@ -44,7 +44,7 @@ fun testUnbound() {
}
fun testBound(a: A) {
use2(fn = { //BLOCK
use2(fn = { // BLOCK
local fun A.foo(p0: Int) {
receiver.foo(xs = [p0]) /*~> Unit */
}
@@ -55,7 +55,7 @@ fun testBound(a: A) {
}
fun testObject() {
use2(fn = { //BLOCK
use2(fn = { // BLOCK
local fun Obj.foo(p0: Int) {
receiver.foo(xs = [p0]) /*~> Unit */
}
@@ -59,7 +59,7 @@ fun testCoercionToUnit() {
}
fun testImportedObjectMember(): String {
return use(fn = { //BLOCK
return use(fn = { // BLOCK
local fun importedObjectMemberWithVarargs(p0: Int): String {
return importedObjectMemberWithVarargs(xs = [p0])
}
@@ -14,7 +14,7 @@ class Host {
}
fun testImplicitThis() {
use(fn = { //BLOCK
use(fn = { // BLOCK
local fun Host.withVararg(p0: Int) {
receiver.withVararg(xs = [p0]) /*~> Unit */
}
@@ -26,7 +26,7 @@ class Host {
fun testBoundReceiverLocalVal() {
val h: Host = TODO("IrConstructorCall")
use(fn = { //BLOCK
use(fn = { // BLOCK
local fun Host.withVararg(p0: Int) {
receiver.withVararg(xs = [p0]) /*~> Unit */
}
@@ -38,7 +38,7 @@ class Host {
fun testBoundReceiverLocalVar() {
var h: Host = TODO("IrConstructorCall")
use(fn = { //BLOCK
use(fn = { // BLOCK
local fun Host.withVararg(p0: Int) {
receiver.withVararg(xs = [p0]) /*~> Unit */
}
@@ -49,7 +49,7 @@ class Host {
}
fun testBoundReceiverParameter(h: Host) {
use(fn = { //BLOCK
use(fn = { // BLOCK
local fun Host.withVararg(p0: Int) {
receiver.withVararg(xs = [p0]) /*~> Unit */
}
@@ -60,7 +60,7 @@ class Host {
}
fun testBoundReceiverExpression() {
use(fn = { //BLOCK
use(fn = { // BLOCK
local fun Host.withVararg(p0: Int) {
receiver.withVararg(xs = [p0]) /*~> Unit */
}
@@ -1,8 +1,8 @@
fun sum(vararg args: Int): Int {
var result: Int = 0
{ //BLOCK
{ // BLOCK
val tmp0_iterator: IntIterator = args.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val arg: Int = tmp0_iterator.next()
result = result.plus(other = arg)
}
@@ -1,8 +1,8 @@
fun test(f: Function0<Unit>) {
return try { //BLOCK
return try { // BLOCK
f.invoke()
}
catch (...) { //BLOCK
catch (...) { // BLOCK
throw e
}
@@ -19,10 +19,10 @@ class C {
}
fun test(nc: C?): C? {
return { //BLOCK
val tmp3_safe_receiver: C? = { //BLOCK
val tmp2_safe_receiver: C? = { //BLOCK
val tmp1_safe_receiver: C? = { //BLOCK
return { // BLOCK
val tmp3_safe_receiver: C? = { // BLOCK
val tmp2_safe_receiver: C? = { // BLOCK
val tmp1_safe_receiver: C? = { // BLOCK
val tmp0_safe_receiver: C? = nc
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -10,14 +10,14 @@ fun test2(mc: MutableCollection<String>) {
}
fun test3() {
{ //BLOCK
{ // BLOCK
val tmp0_safe_receiver: @FlexibleNullability PrintStream? = #out
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
true -> tmp0_safe_receiver /*!! PrintStream */.println(p0 = "Hello,")
}
} /*~> Unit */
{ //BLOCK
{ // BLOCK
val tmp1_safe_receiver: @FlexibleNullability PrintStream? = #out
when {
EQEQ(arg0 = tmp1_safe_receiver, arg1 = null) -> null
@@ -51,9 +51,9 @@ object X1 {
fun test1(a: IntArray) {
var i: Int = 0
{ //BLOCK
{ // BLOCK
val tmp1_array: IntArray = a
val tmp2_index0: Int = { //BLOCK
val tmp2_index0: Int = { // BLOCK
val tmp0: Int = i
i = tmp0.inc()
tmp0
@@ -65,25 +65,25 @@ fun test1(a: IntArray) {
}
fun test2() {
{ //BLOCK
{ // BLOCK
val tmp0_this: X1 = X1
{ //BLOCK
{ // BLOCK
val tmp1: Int = tmp0_this.<get-x1>()
tmp0_this.<set-x1>(<set-?> = tmp1.inc())
tmp1
}
} /*~> Unit */
{ //BLOCK
{ // BLOCK
val tmp2_this: X2 = X2
{ //BLOCK
{ // BLOCK
val tmp3: Int = tmp2_this.<get-x2>()
tmp2_this.<set-x2>(<set-?> = tmp3.inc())
tmp3
}
} /*~> Unit */
{ //BLOCK
{ // BLOCK
val tmp4_this: X3 = X3
{ //BLOCK
{ // BLOCK
val tmp5: Int = tmp4_this.<get-x3>()
tmp4_this.<set-x3>(<set-?> = tmp5.inc())
tmp5
@@ -116,7 +116,7 @@ object Host {
}
operator fun B.plusAssign(b: B) {
{ //BLOCK
{ // BLOCK
val tmp0_this: B = <this>
tmp0_this.<set-s>(<set-?> = tmp0_this.<get-s>().plus(other = b.<get-s>()))
}
@@ -3,7 +3,7 @@ fun length(s: String): Int {
}
fun lengthN(s: String?): Int? {
return { //BLOCK
return { // BLOCK
val tmp0_safe_receiver: String? = s
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
+5 -5
View File
@@ -7,7 +7,7 @@ fun foo(): Any? {
}
fun test1(a: Any?, b: Any): Any {
return { //BLOCK
return { // BLOCK
val tmp0_elvis_lhs: Any? = a
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> b
@@ -17,7 +17,7 @@ fun test1(a: Any?, b: Any): Any {
}
fun test2(a: String?, b: Any): Any {
return { //BLOCK
return { // BLOCK
val tmp0_elvis_lhs: String? = a
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> b
@@ -33,7 +33,7 @@ fun test3(a: Any?, b: Any?): String {
when {
a !is String? -> return ""
}
return { //BLOCK
return { // BLOCK
val tmp0_elvis_lhs: Any? = a
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> b /*as String */
@@ -43,7 +43,7 @@ fun test3(a: Any?, b: Any?): String {
}
fun test4(x: Any): Any {
return { //BLOCK
return { // BLOCK
val tmp0_elvis_lhs: Any? = <get-p>()
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> x
@@ -53,7 +53,7 @@ fun test4(x: Any): Any {
}
fun test5(x: Any): Any {
return { //BLOCK
return { // BLOCK
val tmp0_elvis_lhs: Any? = foo()
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> x
@@ -20,7 +20,7 @@ enum class A : Enum<A> {
fun testVariableAssignment_throws(a: A) {
val x: Int
{ //BLOCK
{ // BLOCK
val tmp0_subject: A = a
when {
EQEQ(arg0 = tmp0_subject, arg1 = A) -> x = 11
@@ -30,7 +30,7 @@ fun testVariableAssignment_throws(a: A) {
}
fun testStatement_empty(a: A) {
{ //BLOCK
{ // BLOCK
val tmp0_subject: A = a
when {
EQEQ(arg0 = tmp0_subject, arg1 = A) -> 1 /*~> Unit */
@@ -39,7 +39,7 @@ fun testStatement_empty(a: A) {
}
fun testParenthesized_throwsJvm(a: A) {
{ //BLOCK
{ // BLOCK
val tmp0_subject: A = a
when {
EQEQ(arg0 = tmp0_subject, arg1 = A) -> 1 /*~> Unit */
@@ -48,7 +48,7 @@ fun testParenthesized_throwsJvm(a: A) {
}
fun testAnnotated_throwsJvm(a: A) {
{ //BLOCK
{ // BLOCK
val tmp0_subject: A = a
when {
EQEQ(arg0 = tmp0_subject, arg1 = A) -> 1 /*~> Unit */
@@ -57,7 +57,7 @@ fun testAnnotated_throwsJvm(a: A) {
}
fun testExpression_throws(a: A): Int {
return { //BLOCK
return { // BLOCK
val tmp0_subject: A = a
when {
EQEQ(arg0 = tmp0_subject, arg1 = A) -> 1
@@ -69,8 +69,8 @@ fun testExpression_throws(a: A): Int {
fun testIfTheElseStatement_empty(a: A, flag: Boolean) {
when {
flag -> 0 /*~> Unit */
true -> { //BLOCK
{ //BLOCK
true -> { // BLOCK
{ // BLOCK
val tmp0_subject: A = a
when {
EQEQ(arg0 = tmp0_subject, arg1 = A) -> 1 /*~> Unit */
@@ -83,8 +83,8 @@ fun testIfTheElseStatement_empty(a: A, flag: Boolean) {
fun testIfTheElseParenthesized_throwsJvm(a: A, flag: Boolean) {
when {
flag -> 0 /*~> Unit */
true -> { //BLOCK
{ //BLOCK
true -> { // BLOCK
{ // BLOCK
val tmp0_subject: A = a
when {
EQEQ(arg0 = tmp0_subject, arg1 = A) -> 1 /*~> Unit */
@@ -97,8 +97,8 @@ fun testIfTheElseParenthesized_throwsJvm(a: A, flag: Boolean) {
fun testIfTheElseAnnotated_throwsJvm(a: A, flag: Boolean) {
when {
flag -> 0 /*~> Unit */
true -> { //BLOCK
{ //BLOCK
true -> { // BLOCK
{ // BLOCK
val tmp0_subject: A = a
when {
EQEQ(arg0 = tmp0_subject, arg1 = A) -> 1 /*~> Unit */
@@ -110,7 +110,7 @@ fun testIfTheElseAnnotated_throwsJvm(a: A, flag: Boolean) {
fun testLambdaResultExpression_throws(a: A) {
local fun <anonymous>(): Int {
return { //BLOCK
return { // BLOCK
val tmp0_subject: A = a
when {
EQEQ(arg0 = tmp0_subject, arg1 = A) -> 1
@@ -1,5 +1,5 @@
fun test(receiver: Any?, fn: @ExtensionFunctionType Function3<Any, Int, String, Unit>): Unit? {
return { //BLOCK
return { // BLOCK
val tmp0_safe_receiver: Any? = receiver
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -1,6 +1,6 @@
fun test(x: Any?, y: Double): Boolean {
return when {
x is Int -> less(arg0 = { //BLOCK
x is Int -> less(arg0 = { // BLOCK
val tmp0_safe_receiver: Any? = x
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -4,7 +4,7 @@ fun testDD(x: Double?, y: Double?): Boolean {
fun testDF(x: Double?, y: Any?): Boolean {
return when {
y is Float? -> ieee754equals(arg0 = x, arg1 = { //BLOCK
y is Float? -> ieee754equals(arg0 = x, arg1 = { // BLOCK
val tmp0_safe_receiver: Any? = y
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -17,7 +17,7 @@ fun testDF(x: Double?, y: Any?): Boolean {
fun testDI(x: Double?, y: Any?): Boolean {
return when {
y is Int? -> ieee754equals(arg0 = x, arg1 = { //BLOCK
y is Int? -> ieee754equals(arg0 = x, arg1 = { // BLOCK
val tmp0_safe_receiver: Any? = y
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -33,7 +33,7 @@ fun testDI2(x: Any?, y: Any?): Boolean {
when {
x is Int? -> y is Double
true -> false
} -> ieee754equals(arg0 = { //BLOCK
} -> ieee754equals(arg0 = { // BLOCK
val tmp0_safe_receiver: Any? = x
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -1,5 +1,5 @@
fun testSimple(x: Double): Int {
return { //BLOCK
return { // BLOCK
val tmp0_subject: Double = x
when {
ieee754equals(arg0 = tmp0_subject, arg1 = 0.0D) -> 0
@@ -12,7 +12,7 @@ fun testSmartCastInWhenSubject(x: Any): Int {
when {
x !is Double -> return -1
}
return { //BLOCK
return { // BLOCK
val tmp0_subject: Any = x
when {
ieee754equals(arg0 = tmp0_subject /*as Double */, arg1 = 0.0D) -> 0
@@ -25,7 +25,7 @@ fun testSmartCastInWhenCondition(x: Double, y: Any): Int {
when {
y !is Double -> return -1
}
return { //BLOCK
return { // BLOCK
val tmp0_subject: Double = x
when {
ieee754equals(arg0 = tmp0_subject, arg1 = y /*as Double */) -> 0
@@ -35,7 +35,7 @@ fun testSmartCastInWhenCondition(x: Double, y: Any): Int {
}
fun testSmartCastInWhenConditionInBranch(x: Any): Int {
return { //BLOCK
return { // BLOCK
val tmp0_subject: Any = x
when {
tmp0_subject is Double.not() -> -1
@@ -52,7 +52,7 @@ fun testSmartCastToDifferentTypes(x: Any, y: Any): Int {
when {
y !is Float -> return -1
}
return { //BLOCK
return { // BLOCK
val tmp0_subject: Any = x
when {
ieee754equals(arg0 = tmp0_subject /*as Double */, arg1 = y /*as Float */.toDouble()) -> 0
@@ -66,7 +66,7 @@ fun foo(x: Double): Double {
}
fun testWithPrematureExitInConditionSubexpression(x: Any): Int {
return { //BLOCK
return { // BLOCK
val tmp0_subject: Any = x
when {
EQEQ(arg0 = tmp0_subject, arg1 = foo(x = when {
+10 -10
View File
@@ -1,18 +1,18 @@
fun testEmpty(ss: List<String>) {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: Iterator<String> = ss.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val s: String = tmp0_iterator.next()
}
}
}
fun testIterable(ss: List<String>) {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: Iterator<String> = ss.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val s: String = tmp0_iterator.next()
{ //BLOCK
{ // BLOCK
println(message = s)
}
}
@@ -20,13 +20,13 @@ fun testIterable(ss: List<String>) {
}
fun testDestructuring(pp: List<Pair<Int, String>>) {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: Iterator<Pair<Int, String>> = pp.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val tmp1_loop_parameter: Pair<Int, String> = tmp0_iterator.next()
val i: Int = tmp1_loop_parameter.component1()
val s: String = tmp1_loop_parameter.component2()
{ //BLOCK
{ // BLOCK
println(message = i)
println(message = s)
}
@@ -35,9 +35,9 @@ fun testDestructuring(pp: List<Pair<Int, String>>) {
}
fun testRange() {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: IntIterator = 1.rangeTo(other = 10).iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val i: Int = tmp0_iterator.next()
}
}
@@ -1,9 +1,9 @@
fun testForBreak1(ss: List<String>) {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: Iterator<String> = ss.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val s: String = tmp0_iterator.next()
{ //BLOCK
{ // BLOCK
break
}
}
@@ -11,16 +11,16 @@ fun testForBreak1(ss: List<String>) {
}
fun testForBreak2(ss: List<String>) {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: Iterator<String> = ss.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val s1: String = tmp0_iterator.next()
{ //BLOCK
{ //BLOCK
{ // BLOCK
{ // BLOCK
val tmp1_iterator: Iterator<String> = ss.iterator()
while (tmp1_iterator.hasNext()) { //BLOCK
while (tmp1_iterator.hasNext()) { // BLOCK
val s2: String = tmp1_iterator.next()
{ //BLOCK
{ // BLOCK
break
break
break
@@ -34,11 +34,11 @@ fun testForBreak2(ss: List<String>) {
}
fun testForContinue1(ss: List<String>) {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: Iterator<String> = ss.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val s: String = tmp0_iterator.next()
{ //BLOCK
{ // BLOCK
continue
}
}
@@ -46,16 +46,16 @@ fun testForContinue1(ss: List<String>) {
}
fun testForContinue2(ss: List<String>) {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: Iterator<String> = ss.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val s1: String = tmp0_iterator.next()
{ //BLOCK
{ //BLOCK
{ // BLOCK
{ // BLOCK
val tmp1_iterator: Iterator<String> = ss.iterator()
while (tmp1_iterator.hasNext()) { //BLOCK
while (tmp1_iterator.hasNext()) { // BLOCK
val s2: String = tmp1_iterator.next()
{ //BLOCK
{ // BLOCK
continue
continue
continue
@@ -37,9 +37,9 @@ interface IReceiver {
}
operator fun IntCell.next(): Int {
return { //BLOCK
return { // BLOCK
val tmp0_this: IntCell = <this>
{ //BLOCK
{ // BLOCK
val tmp1: Int = tmp0_this.<get-value>()
tmp0_this.<set-value>(<set-?> = tmp1.dec())
tmp1
@@ -53,11 +53,11 @@ interface IReceiver {
}
fun IReceiver.test() {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: IntCell = <this>.iterator($receiver = FiveTimes)
while (<this>.hasNext($receiver = tmp0_iterator)) { //BLOCK
while (<this>.hasNext($receiver = tmp0_iterator)) { // BLOCK
val i: Int = <this>.next($receiver = tmp0_iterator)
{ //BLOCK
{ // BLOCK
println(message = i)
}
}
@@ -22,7 +22,7 @@ class J {
}
val fsi: Fn<String, Int>
field = { //BLOCK
field = { // BLOCK
local class <no name provided> : Fn<String, Int> {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -45,7 +45,7 @@ val fsi: Fn<String, Int>
get
val fis: Fn<Int, String>
field = { //BLOCK
field = { // BLOCK
local class <no name provided> : Fn<Int, String> {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -7,7 +7,7 @@ fun interface MyRunnable {
fun test(a: Any, r: MyRunnable) {
when {
a is MyRunnable -> { //BLOCK
a is MyRunnable -> { // BLOCK
foo(rs = [ local fun <anonymous>() {
return Unit
}
@@ -21,7 +21,7 @@ fun <T> test0(a: T) where T : KRunnable, T : Function0<Unit> {
fun test1(a: Function0<Unit>) {
when {
a is KRunnable -> { //BLOCK
a is KRunnable -> { // BLOCK
run1(r = a /*as KRunnable */)
}
}
@@ -34,7 +34,7 @@ fun test2(a: KRunnable) {
fun test3(a: Function0<Unit>) {
when {
a is KRunnable -> { //BLOCK
a is KRunnable -> { // BLOCK
run2(r1 = a /*as KRunnable */, r2 = a /*as KRunnable */)
}
}
@@ -42,7 +42,7 @@ fun test3(a: Function0<Unit>) {
fun test4(a: Function0<Unit>, b: Function0<Unit>) {
when {
a is KRunnable -> { //BLOCK
a is KRunnable -> { // BLOCK
run2(r1 = a /*as KRunnable */, r2 = b /*-> KRunnable */)
}
}
@@ -50,7 +50,7 @@ fun test4(a: Function0<Unit>, b: Function0<Unit>) {
fun test5(a: Any) {
when {
a is KRunnable -> { //BLOCK
a is KRunnable -> { // BLOCK
run1(r = a /*as KRunnable */)
}
}
@@ -58,7 +58,7 @@ fun test5(a: Any) {
fun test5x(a: Any) {
when {
a is KRunnable -> { //BLOCK
a is KRunnable -> { // BLOCK
a as Function0<Unit> /*~> Unit */
run1(r = a /*as KRunnable */)
}
+4 -4
View File
@@ -8,7 +8,7 @@ fun test(i: Int): Int {
fun testEmptyBranches1(flag: Boolean) {
when {
flag -> { //BLOCK
flag -> { // BLOCK
}
true -> true /*~> Unit */
}
@@ -19,20 +19,20 @@ fun testEmptyBranches1(flag: Boolean) {
fun testEmptyBranches2(flag: Boolean) {
when {
flag -> { //BLOCK
flag -> { // BLOCK
}
true -> true /*~> Unit */
}
when {
flag -> true /*~> Unit */
true -> { //BLOCK
true -> { // BLOCK
}
}
}
fun testEmptyBranches3(flag: Boolean) {
when {
flag -> { //BLOCK
flag -> { // BLOCK
}
true -> true /*~> Unit */
}
@@ -9,11 +9,11 @@ val arr: IntArray
fun testVarPrefix() {
var x: Int = 0
val x1: Int = { //BLOCK
val x1: Int = { // BLOCK
x = x.inc()
x
}
val x2: Int = { //BLOCK
val x2: Int = { // BLOCK
x = x.dec()
x
}
@@ -21,12 +21,12 @@ fun testVarPrefix() {
fun testVarPostfix() {
var x: Int = 0
val x1: Int = { //BLOCK
val x1: Int = { // BLOCK
val tmp0: Int = x
x = tmp0.inc()
tmp0
}
val x2: Int = { //BLOCK
val x2: Int = { // BLOCK
val tmp1: Int = x
x = tmp1.dec()
tmp1
@@ -34,14 +34,14 @@ fun testVarPostfix() {
}
fun testPropPrefix() {
val p1: Int = { //BLOCK
{ //BLOCK
val p1: Int = { // BLOCK
{ // BLOCK
<set-p>(<set-?> = <get-p>().inc())
<get-p>()
}
}
val p2: Int = { //BLOCK
{ //BLOCK
val p2: Int = { // BLOCK
{ // BLOCK
<set-p>(<set-?> = <get-p>().dec())
<get-p>()
}
@@ -49,15 +49,15 @@ fun testPropPrefix() {
}
fun testPropPostfix() {
val p1: Int = { //BLOCK
{ //BLOCK
val p1: Int = { // BLOCK
{ // BLOCK
val tmp0: Int = <get-p>()
<set-p>(<set-?> = tmp0.inc())
tmp0
}
}
val p2: Int = { //BLOCK
{ //BLOCK
val p2: Int = { // BLOCK
{ // BLOCK
<set-p>(<set-?> = <get-p>().dec())
<get-p>()
}
@@ -65,13 +65,13 @@ fun testPropPostfix() {
}
fun testArrayPrefix() {
val a1: Int = { //BLOCK
val a1: Int = { // BLOCK
val tmp0_array: IntArray = <get-arr>()
val tmp1_index0: Int = 0
tmp0_array.set(index = tmp1_index0, value = tmp0_array.get(index = tmp1_index0).inc())
tmp0_array.get(index = tmp1_index0)
}
val a2: Int = { //BLOCK
val a2: Int = { // BLOCK
val tmp2_array: IntArray = <get-arr>()
val tmp3_index0: Int = 0
tmp2_array.set(index = tmp3_index0, value = tmp2_array.get(index = tmp3_index0).dec())
@@ -80,14 +80,14 @@ fun testArrayPrefix() {
}
fun testArrayPostfix() {
val a1: Int = { //BLOCK
val a1: Int = { // BLOCK
val tmp0_array: IntArray = <get-arr>()
val tmp1_index0: Int = 0
val tmp2: Int = tmp0_array.get(index = tmp1_index0)
tmp0_array.set(index = tmp1_index0, value = tmp2.inc())
tmp2
}
val a2: Int = { //BLOCK
val a2: Int = { // BLOCK
val tmp3_array: IntArray = <get-arr>()
val tmp4_index0: Int = 0
val tmp5: Int = tmp3_array.get(index = tmp4_index0)
@@ -1,15 +1,15 @@
fun <F : Any?> test(j: J<F>) {
j.getFoo<F>() /*~> Unit */
j.setFoo<F>(x = 1)
{ //BLOCK
{ // BLOCK
val tmp0_receiver: J<F> = j
{ //BLOCK
{ // BLOCK
val tmp1: Int = tmp0_receiver.getFoo<F>()
tmp0_receiver.setFoo<F>(x = tmp1.inc())
tmp1
}
} /*~> Unit */
{ //BLOCK
{ // BLOCK
val tmp2_receiver: J<F> = j
tmp2_receiver.setFoo<F>(x = tmp2_receiver.getFoo<F>().plus(other = 1))
}
@@ -1,15 +1,15 @@
fun test(j: J) {
j.getFoo() /*~> Unit */
j.setFoo(x = 1)
{ //BLOCK
{ // BLOCK
val tmp0_receiver: J = j
{ //BLOCK
{ // BLOCK
val tmp1: Int = tmp0_receiver.getFoo()
tmp0_receiver.setFoo(x = tmp1.inc())
tmp1
}
} /*~> Unit */
{ //BLOCK
{ // BLOCK
val tmp2_receiver: J = j
tmp2_receiver.setFoo(x = tmp2_receiver.getFoo().plus(other = 1))
}
@@ -20,7 +20,7 @@ class TestClass {
val test: Int
field = when {
true -> { //BLOCK
true -> { // BLOCK
#out /*!! PrintStream */.println(p0 = "TestClass/test")
42
}
+2 -2
View File
@@ -39,11 +39,11 @@ class Test1 : A {
TODO("IrDelegatingConstructorCall")
/* InstanceInitializerCall */
{ //BLOCK
{ // BLOCK
val tmp0_this: Test1 = <this>
tmp0_this.<get-x>().plusAssign(x = 42)
}
{ //BLOCK
{ // BLOCK
val tmp1_this: Test1 = <this>
tmp1_this.<set-y>(<set-?> = tmp1_this.<get-y>().plus(other = 42))
}
+1 -1
View File
@@ -4,7 +4,7 @@ inline fun foo(): Boolean {
fun run(x: Boolean, y: Boolean): String {
var z: Int = 10
{ //BLOCK
{ // BLOCK
do// COMPOSITE {
z = z.plus(other = 1)
when {
+1 -1
View File
@@ -1,7 +1,7 @@
fun box(): String {
var r: String = ""
when {
EQEQ(arg0 = r, arg1 = "").not() -> { //BLOCK
EQEQ(arg0 = r, arg1 = "").not() -> { // BLOCK
}
true -> r = r.plus(other = "O")
}
+2 -2
View File
@@ -22,7 +22,7 @@ fun testSimpleAssignment(a: A) {
}
fun testPostfixIncrement(a: A): Int {
return { //BLOCK
return { // BLOCK
val tmp0_array: A = a
val tmp1_index0: Int = 1
val tmp2_index1: Int = 2
@@ -33,7 +33,7 @@ fun testPostfixIncrement(a: A): Int {
}
fun testCompoundAssignment(a: A) {
{ //BLOCK
{ // BLOCK
val tmp0_array: A = a
val tmp1_index0: Int = 1
val tmp2_index1: Int = 2
+2 -2
View File
@@ -22,7 +22,7 @@ fun testSimpleAssignment(a: A) {
}
fun testPostfixIncrement(a: A): Int {
return { //BLOCK
return { // BLOCK
val tmp0_array: A = a
val tmp1_index0: Int = 1
val tmp2: Int = get($receiver = tmp0_array, i = tmp1_index0)
@@ -32,7 +32,7 @@ fun testPostfixIncrement(a: A): Int {
}
fun testCompoundAssignment(a: A) {
{ //BLOCK
{ // BLOCK
val tmp0_array: A = a
val tmp1_index0: Int = 1
set($receiver = tmp0_array, i = tmp1_index0, v = get($receiver = tmp0_array, i = tmp1_index0).plus(other = 10))
+3 -3
View File
@@ -9,21 +9,21 @@ interface X {
}
fun test(x: X, nx: X?) {
{ //BLOCK
{ // BLOCK
val tmp0_this: X = x
plusAssign<Int>($receiver = tmp0_this.<get-xs>(), element = 1)
}
plusAssign<Int>($receiver = x.f(), element = 2)
plusAssign<Int>($receiver = x.<get-xs>() as MutableList<Int>, element = 3)
plusAssign<Int>($receiver = x.f() as MutableList<Int>, element = 4)
plusAssign<Int>($receiver = CHECK_NOT_NULL<MutableList<Any>>(arg0 = { //BLOCK
plusAssign<Int>($receiver = CHECK_NOT_NULL<MutableList<Any>>(arg0 = { // BLOCK
val tmp1_safe_receiver: X? = nx
when {
EQEQ(arg0 = tmp1_safe_receiver, arg1 = null) -> null
true -> tmp1_safe_receiver.<get-xs>()
}
}), element = 5)
plusAssign<Int>($receiver = CHECK_NOT_NULL<MutableList<Any>>(arg0 = { //BLOCK
plusAssign<Int>($receiver = CHECK_NOT_NULL<MutableList<Any>>(arg0 = { // BLOCK
val tmp2_safe_receiver: X? = nx
when {
EQEQ(arg0 = tmp2_safe_receiver, arg1 = null) -> null
+12 -12
View File
@@ -3,17 +3,17 @@ fun <T : Any?> magic(): T {
}
fun <T : Any?> test(value: T, value2: T) {
val x1: Any = { //BLOCK
val x1: Any = { // BLOCK
val tmp0_elvis_lhs: T = value
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> 42
true -> tmp0_elvis_lhs
}
}
val x2: Any = { //BLOCK
val x2: Any = { // BLOCK
val tmp2_elvis_lhs: T = value
when {
EQEQ(arg0 = tmp2_elvis_lhs, arg1 = null) -> { //BLOCK
EQEQ(arg0 = tmp2_elvis_lhs, arg1 = null) -> { // BLOCK
val tmp1_elvis_lhs: T = value2
when {
EQEQ(arg0 = tmp1_elvis_lhs, arg1 = null) -> 42
@@ -23,8 +23,8 @@ fun <T : Any?> test(value: T, value2: T) {
true -> tmp2_elvis_lhs
}
}
val x3: Any = { //BLOCK
val tmp4_elvis_lhs: T = { //BLOCK
val x3: Any = { // BLOCK
val tmp4_elvis_lhs: T = { // BLOCK
val tmp3_elvis_lhs: T = value
when {
EQEQ(arg0 = tmp3_elvis_lhs, arg1 = null) -> value2
@@ -36,8 +36,8 @@ fun <T : Any?> test(value: T, value2: T) {
true -> tmp4_elvis_lhs
}
}
val x4: Any = { //BLOCK
val tmp6_elvis_lhs: T = { //BLOCK
val x4: Any = { // BLOCK
val tmp6_elvis_lhs: T = { // BLOCK
val tmp5_elvis_lhs: T = value
when {
EQEQ(arg0 = tmp5_elvis_lhs, arg1 = null) -> value2
@@ -49,15 +49,15 @@ fun <T : Any?> test(value: T, value2: T) {
true -> tmp6_elvis_lhs
}
}
val x5: Any = { //BLOCK
val x5: Any = { // BLOCK
val tmp7_elvis_lhs: Any? = magic<Any?>()
when {
EQEQ(arg0 = tmp7_elvis_lhs, arg1 = null) -> 42
true -> tmp7_elvis_lhs
}
}
val x6: Any = { //BLOCK
val tmp9_elvis_lhs: Any? = { //BLOCK
val x6: Any = { // BLOCK
val tmp9_elvis_lhs: Any? = { // BLOCK
val tmp8_elvis_lhs: T = value
when {
EQEQ(arg0 = tmp8_elvis_lhs, arg1 = null) -> magic<Any?>()
@@ -69,8 +69,8 @@ fun <T : Any?> test(value: T, value2: T) {
true -> tmp9_elvis_lhs
}
}
val x7: Any = { //BLOCK
val tmp11_elvis_lhs: Any? = { //BLOCK
val x7: Any = { // BLOCK
val tmp11_elvis_lhs: Any? = { // BLOCK
val tmp10_elvis_lhs: Any? = magic<Any?>()
when {
EQEQ(arg0 = tmp10_elvis_lhs, arg1 = null) -> value
+1 -1
View File
@@ -26,7 +26,7 @@ val aFloat: A<Float>
get
val aInt: Float
field = { //BLOCK
field = { // BLOCK
val tmp0_array: A<Float> = <get-aFloat>()
val tmp1_index0: Int = 1
val tmp2: Float = tmp0_array.get(i = tmp1_index0)
+2 -2
View File
@@ -16,7 +16,7 @@ fun test1(a: Any) {
}
fun test2(a: Any) {
{ //BLOCK
{ // BLOCK
val tmp0_array: Any = a
val tmp1_index0: Function0<Unit> = local fun <anonymous>() {
return Unit
@@ -27,7 +27,7 @@ fun test2(a: Any) {
}
fun test3(a: Any) {
{ //BLOCK
{ // BLOCK
val tmp0_array: Any = a
val tmp1_index0: Function0<Unit> = local fun <anonymous>() {
return Unit
@@ -38,7 +38,7 @@ class Host {
get
fun Outer.test(): Inner {
return { //BLOCK
return { // BLOCK
local class <no name provided> : Inner {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -57,7 +57,7 @@ object Z {
get
val anObject: Any
field = { //BLOCK
field = { // BLOCK
local class <no name provided> {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -16,7 +16,7 @@ class C {
}
fun test(nc: C?) {
{ //BLOCK
{ // BLOCK
val tmp0_safe_receiver: C? = nc
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null /*~> Unit */
@@ -20,7 +20,7 @@ var C?.p: Int
}
operator fun Int?.inc(): Int? {
return { //BLOCK
return { // BLOCK
val tmp0_safe_receiver: Int? = <this>
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -37,13 +37,13 @@ operator fun Int?.set(index: Int, value: Int) {
}
fun testProperty(nc: C?) {
{ //BLOCK
{ // BLOCK
val tmp0_safe_receiver: C? = nc
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
true -> { //BLOCK
true -> { // BLOCK
val tmp1_receiver: C? = tmp0_safe_receiver
{ //BLOCK
{ // BLOCK
val tmp2: Int = <get-p>($receiver = tmp1_receiver)
<set-p>($receiver = tmp1_receiver, value = inc($receiver = tmp2))
tmp2
@@ -54,8 +54,8 @@ fun testProperty(nc: C?) {
}
fun testArrayAccess(nc: C?) {
{ //BLOCK
val tmp1_array: Int? = { //BLOCK
{ // BLOCK
val tmp1_array: Int? = { // BLOCK
val tmp0_safe_receiver: C? = nc
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
+6 -6
View File
@@ -26,7 +26,7 @@ interface IHost {
}
fun test1(x: String?): Int? {
return { //BLOCK
return { // BLOCK
val tmp0_safe_receiver: String? = x
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -36,7 +36,7 @@ fun test1(x: String?): Int? {
}
fun test2(x: String?): Int? {
return { //BLOCK
return { // BLOCK
val tmp0_safe_receiver: String? = x
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -46,7 +46,7 @@ fun test2(x: String?): Int? {
}
fun test3(x: String?, y: Any?): Boolean? {
return { //BLOCK
return { // BLOCK
val tmp0_safe_receiver: String? = x
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -56,7 +56,7 @@ fun test3(x: String?, y: Any?): Boolean? {
}
fun test4(x: Ref?) {
{ //BLOCK
{ // BLOCK
val tmp0_safe_receiver: Ref? = x
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null /*~> Unit */
@@ -66,7 +66,7 @@ fun test4(x: Ref?) {
}
fun IHost.test5(s: String?): Int? {
return { //BLOCK
return { // BLOCK
val tmp0_safe_receiver: String? = s
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -80,7 +80,7 @@ fun Int.foo(): Int {
}
fun box() {
{ //BLOCK
{ // BLOCK
val tmp0_safe_receiver: Int = 42
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -1,6 +1,6 @@
fun f(x: Any): String {
when {
x is A<*> -> { //BLOCK
x is A<*> -> { // BLOCK
return x /*as A<T> */.call(block = local fun <anonymous>(y: Any?): @FlexibleNullability String? {
return "OK"
}
@@ -1,6 +1,6 @@
fun test1(a: Function0<Unit>) {
when {
a is Runnable -> { //BLOCK
a is Runnable -> { // BLOCK
runStatic(r = a /*as Runnable */)
}
}
@@ -8,7 +8,7 @@ fun test1(a: Function0<Unit>) {
fun test2(a: Function0<Unit>) {
when {
a is Runnable -> { //BLOCK
a is Runnable -> { // BLOCK
TODO("IrConstructorCall").run1(r = a /*as Runnable */)
}
}
@@ -16,7 +16,7 @@ fun test2(a: Function0<Unit>) {
fun test3(a: Function0<Unit>) {
when {
a is Runnable -> { //BLOCK
a is Runnable -> { // BLOCK
TODO("IrConstructorCall").run2(r1 = a /*as Runnable */, r2 = a /*as Runnable */)
}
}
@@ -24,7 +24,7 @@ fun test3(a: Function0<Unit>) {
fun test4(a: Function0<Unit>, b: Function0<Unit>) {
when {
a is Runnable -> { //BLOCK
a is Runnable -> { // BLOCK
TODO("IrConstructorCall").run2(r1 = a /*-> @FlexibleNullability Runnable? */, r2 = b /*-> @FlexibleNullability Runnable? */)
}
}
@@ -32,7 +32,7 @@ fun test4(a: Function0<Unit>, b: Function0<Unit>) {
fun test5(a: Any) {
when {
a is Runnable -> { //BLOCK
a is Runnable -> { // BLOCK
TODO("IrConstructorCall").run1(r = a /*as Runnable */)
}
}
@@ -40,7 +40,7 @@ fun test5(a: Any) {
fun test5x(a: Any) {
when {
a is Runnable -> { //BLOCK
a is Runnable -> { // BLOCK
a as Function0<Unit> /*~> Unit */
TODO("IrConstructorCall").run1(r = a /*as Runnable */)
}
@@ -7,7 +7,7 @@ class Derived : Base {
fun setValue(v: Any) {
when {
v is String -> { //BLOCK
v is String -> { // BLOCK
#value = v /*as String */
}
}
@@ -21,7 +21,7 @@ fun produceFun(): Function0<Unit> {
}
fun testSimple(fn: Function0<Unit>) {
useSuspend(sfn = { //BLOCK
useSuspend(sfn = { // BLOCK
local suspend fun Function0<Unit>.suspendConversion0() {
callee.invoke()
}
@@ -32,7 +32,7 @@ fun testSimple(fn: Function0<Unit>) {
}
fun testSimpleNonVal() {
useSuspend(sfn = { //BLOCK
useSuspend(sfn = { // BLOCK
local suspend fun Function0<Unit>.suspendConversion0() {
callee.invoke()
}
@@ -43,7 +43,7 @@ fun testSimpleNonVal() {
}
fun testExtAsExt(fn: @ExtensionFunctionType Function1<Int, Unit>) {
useSuspendExt(sfn = { //BLOCK
useSuspendExt(sfn = { // BLOCK
local suspend fun @ExtensionFunctionType Function1<Int, Unit>.suspendConversion0(p0: Int) {
callee.invoke(p1 = p0)
}
@@ -54,7 +54,7 @@ fun testExtAsExt(fn: @ExtensionFunctionType Function1<Int, Unit>) {
}
fun testExtAsSimple(fn: @ExtensionFunctionType Function1<Int, Unit>) {
useSuspendArg(sfn = { //BLOCK
useSuspendArg(sfn = { // BLOCK
local suspend fun Function1<Int, Unit>.suspendConversion0(p0: Int) {
callee.invoke(p1 = p0)
}
@@ -65,7 +65,7 @@ fun testExtAsSimple(fn: @ExtensionFunctionType Function1<Int, Unit>) {
}
fun testSimpleAsExt(fn: Function1<Int, Unit>) {
useSuspendExt(sfn = { //BLOCK
useSuspendExt(sfn = { // BLOCK
local suspend fun @ExtensionFunctionType Function1<Int, Unit>.suspendConversion0(p0: Int) {
callee.invoke(p1 = p0)
}
@@ -76,7 +76,7 @@ fun testSimpleAsExt(fn: Function1<Int, Unit>) {
}
fun testSimpleAsSimpleT(fn: Function1<Int, Unit>) {
useSuspendArgT<Int>(sfn = { //BLOCK
useSuspendArgT<Int>(sfn = { // BLOCK
local suspend fun Function1<Int, Unit>.suspendConversion0(p0: Int) {
callee.invoke(p1 = p0)
}
@@ -87,7 +87,7 @@ fun testSimpleAsSimpleT(fn: Function1<Int, Unit>) {
}
fun testSimpleAsExtT(fn: Function1<Int, Unit>) {
useSuspendExtT<Int>(sfn = { //BLOCK
useSuspendExtT<Int>(sfn = { // BLOCK
local suspend fun @ExtensionFunctionType Function1<Int, Unit>.suspendConversion0(p0: Int) {
callee.invoke(p1 = p0)
}
@@ -98,7 +98,7 @@ fun testSimpleAsExtT(fn: Function1<Int, Unit>) {
}
fun testExtAsSimpleT(fn: @ExtensionFunctionType Function1<Int, Unit>) {
useSuspendArgT<Int>(sfn = { //BLOCK
useSuspendArgT<Int>(sfn = { // BLOCK
local suspend fun Function1<Int, Unit>.suspendConversion0(p0: Int) {
callee.invoke(p1 = p0)
}
@@ -109,7 +109,7 @@ fun testExtAsSimpleT(fn: @ExtensionFunctionType Function1<Int, Unit>) {
}
fun testExtAsExtT(fn: @ExtensionFunctionType Function1<Int, Unit>) {
useSuspendExtT<Int>(sfn = { //BLOCK
useSuspendExtT<Int>(sfn = { // BLOCK
local suspend fun @ExtensionFunctionType Function1<Int, Unit>.suspendConversion0(p0: Int) {
callee.invoke(p1 = p0)
}
@@ -120,7 +120,7 @@ fun testExtAsExtT(fn: @ExtensionFunctionType Function1<Int, Unit>) {
}
fun <S : Any?> testSimpleSAsSimpleT(fn: Function1<S, Unit>) {
useSuspendArgT<S>(sfn = { //BLOCK
useSuspendArgT<S>(sfn = { // BLOCK
local suspend fun Function1<S, Unit>.suspendConversion0(p0: S) {
callee.invoke(p1 = p0)
}
@@ -131,7 +131,7 @@ fun <S : Any?> testSimpleSAsSimpleT(fn: Function1<S, Unit>) {
}
fun <S : Any?> testSimpleSAsExtT(fn: Function1<S, Unit>) {
useSuspendExtT<S>(sfn = { //BLOCK
useSuspendExtT<S>(sfn = { // BLOCK
local suspend fun @ExtensionFunctionType Function1<S, Unit>.suspendConversion0(p0: S) {
callee.invoke(p1 = p0)
}
@@ -142,7 +142,7 @@ fun <S : Any?> testSimpleSAsExtT(fn: Function1<S, Unit>) {
}
fun <S : Any?> testExtSAsSimpleT(fn: @ExtensionFunctionType Function1<S, Unit>) {
useSuspendArgT<S>(sfn = { //BLOCK
useSuspendArgT<S>(sfn = { // BLOCK
local suspend fun Function1<S, Unit>.suspendConversion0(p0: S) {
callee.invoke(p1 = p0)
}
@@ -153,7 +153,7 @@ fun <S : Any?> testExtSAsSimpleT(fn: @ExtensionFunctionType Function1<S, Unit>)
}
fun <S : Any?> testExtSAsExtT(fn: @ExtensionFunctionType Function1<S, Unit>) {
useSuspendExtT<S>(sfn = { //BLOCK
useSuspendExtT<S>(sfn = { // BLOCK
local suspend fun @ExtensionFunctionType Function1<S, Unit>.suspendConversion0(p0: S) {
callee.invoke(p1 = p0)
}
@@ -165,7 +165,7 @@ fun <S : Any?> testExtSAsExtT(fn: @ExtensionFunctionType Function1<S, Unit>) {
fun testSmartCastWithSuspendConversion(a: Any) {
a as Function0<Unit> /*~> Unit */
useSuspend(sfn = { //BLOCK
useSuspend(sfn = { // BLOCK
local suspend fun Function0<Unit>.suspendConversion0() {
callee.invoke()
}
@@ -178,7 +178,7 @@ fun testSmartCastWithSuspendConversion(a: Any) {
fun testSmartCastOnVarWithSuspendConversion(a: Any) {
var b: Any = a
b as Function0<Unit> /*~> Unit */
useSuspend(sfn = { //BLOCK
useSuspend(sfn = { // BLOCK
local suspend fun Function0<Unit>.suspendConversion0() {
callee.invoke()
}
@@ -9,7 +9,7 @@ class C {
get
init {
#s = { //BLOCK
#s = { // BLOCK
val tmp0_safe_receiver: Any? = x
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
@@ -31,7 +31,7 @@ class Outer<T : Any?> {
}
fun Outer<Int>.test(): Inner<Int> {
return { //BLOCK
return { // BLOCK
local class <no name provided> : Inner<Int> {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -1,5 +1,5 @@
fun WithCompanion.test() {
val test1: <no name provided> = { //BLOCK
val test1: <no name provided> = { // BLOCK
local class <no name provided> : WithCompanion {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -15,7 +15,7 @@ fun WithCompanion.test() {
TODO("IrConstructorCall")
}
val test2: <no name provided> = { //BLOCK
val test2: <no name provided> = { // BLOCK
local class <no name provided> : WithCompanion {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
+1 -1
View File
@@ -4,7 +4,7 @@ fun test1() {
fun testImplicitCast(a: Any) {
when {
a is Throwable -> { //BLOCK
a is Throwable -> { // BLOCK
throw a /*as Throwable */
}
}
+6 -6
View File
@@ -1,25 +1,25 @@
fun test1() {
try { //BLOCK
try { // BLOCK
println()
}
catch (...) { //BLOCK
catch (...) { // BLOCK
println()
}
finally { //BLOCK
finally { // BLOCK
println()
}
}
fun test2(): Int {
return try { //BLOCK
return try { // BLOCK
println()
42
}
catch (...) { //BLOCK
catch (...) { // BLOCK
println()
24
}
finally { //BLOCK
finally { // BLOCK
println()
555 /*~> Unit */
}
@@ -2,10 +2,10 @@ fun testImplicitCast(a: Any) {
when {
a !is String -> return Unit
}
val t: String = try { //BLOCK
val t: String = try { // BLOCK
a
} /*as String */
catch (...) { //BLOCK
catch (...) { // BLOCK
""
}
@@ -18,8 +18,8 @@ fun test3(): String {
}
fun test4(ns: String?): String? {
return { //BLOCK
val tmp1_safe_receiver: Function0<String>? = { //BLOCK
return { // BLOCK
val tmp1_safe_receiver: Function0<String>? = { // BLOCK
val tmp0_safe_receiver: String? = ns
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
+2 -2
View File
@@ -11,7 +11,7 @@ object A {
}
fun testWithSubject(x: Any?): String {
return { //BLOCK
return { // BLOCK
val tmp0_subject: Any? = x
when {
EQEQ(arg0 = tmp0_subject, arg1 = null) -> "null"
@@ -36,7 +36,7 @@ fun test(x: Any?): String {
}
fun testComma(x: Int): String {
return { //BLOCK
return { // BLOCK
val tmp0_subject: Int = x
when {
when {
@@ -1,5 +1,5 @@
fun foo(x: Int) {
{ //BLOCK
{ // BLOCK
val tmp0_subject: Int = x
when {
EQEQ(arg0 = tmp0_subject, arg1 = 0) -> 0 /*~> Unit */
+1 -1
View File
@@ -1,5 +1,5 @@
fun toString(grade: String): String {
{ //BLOCK
{ // BLOCK
val tmp0_subject: String = grade
when {
EQEQ(arg0 = tmp0_subject, arg1 = "A") -> return "Excellent"
@@ -3,7 +3,7 @@ fun run(block: Function0<Unit>) {
fun branch(x: Int) {
return run(block = local fun <anonymous>() {
{ //BLOCK
{ // BLOCK
val tmp0_subject: Int = x
when {
EQEQ(arg0 = tmp0_subject, arg1 = 1) -> TODO(reason = "1")
@@ -1,7 +1,7 @@
fun test(b: Boolean, i: Int) {
when {
b -> { //BLOCK
{ //BLOCK
b -> { // BLOCK
{ // BLOCK
val tmp0_subject: Int = i
when {
EQEQ(arg0 = tmp0_subject, arg1 = 0) -> 1 /*~> Unit */
@@ -3,7 +3,7 @@ fun foo(): Any {
}
fun test(): Int {
return { //BLOCK
return { // BLOCK
val y: Any = foo()
when {
EQEQ(arg0 = y, arg1 = 42) -> 1
+11 -11
View File
@@ -1,31 +1,31 @@
fun test() {
var x: Int = 0
while (less(arg0 = x, arg1 = 0))
while (less(arg0 = x, arg1 = 5)) { //BLOCK
while (less(arg0 = x, arg1 = 5)) { // BLOCK
val tmp0: Int = x
x = tmp0.inc()
tmp0
} /*~> Unit */
while (less(arg0 = x, arg1 = 10)) { //BLOCK
{ //BLOCK
while (less(arg0 = x, arg1 = 10)) { // BLOCK
{ // BLOCK
val tmp1: Int = x
x = tmp1.inc()
tmp1
} /*~> Unit */
}
{ //BLOCK
{ // BLOCK
do while (less(arg0 = x, arg1 = 0))
}
{ //BLOCK
do{ //BLOCK
{ // BLOCK
do{ // BLOCK
val tmp2: Int = x
x = tmp2.inc()
tmp2
} /*~> Unit */ while (less(arg0 = x, arg1 = 15))
}
{ //BLOCK
{ // BLOCK
do// COMPOSITE {
{ //BLOCK
{ // BLOCK
val tmp3: Int = x
x = tmp3.inc()
tmp3
@@ -37,10 +37,10 @@ fun test() {
fun testSmartcastInCondition() {
val a: Any? = null
when {
a is Boolean -> { //BLOCK
while (a /*as Boolean */) { //BLOCK
a is Boolean -> { // BLOCK
while (a /*as Boolean */) { // BLOCK
}
{ //BLOCK
{ // BLOCK
do// COMPOSITE {
// } while (a /*as Boolean */)
}
@@ -57,12 +57,12 @@ private val registrationMap: HashMap<Type, Any>
private get
fun resolveClashesIfAny(container: ComponentContainer, clashResolvers: List<PlatformExtensionsClashResolver<*>>) {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: Iterator<PlatformExtensionsClashResolver<*>> = clashResolvers.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val resolver: PlatformExtensionsClashResolver<*> = tmp0_iterator.next()
{ //BLOCK
val clashedComponents: Collection<ComponentDescriptor> = { //BLOCK
{ // BLOCK
val clashedComponents: Collection<ComponentDescriptor> = { // BLOCK
val tmp1_elvis_lhs: Collection<ComponentDescriptor>? = <get-registrationMap>().get(key = resolver.<get-applicableTo>()) as? Collection<ComponentDescriptor>
when {
EQEQ(arg0 = tmp1_elvis_lhs, arg1 = null) -> continue
@@ -65,13 +65,13 @@ class DeepCopyIrTreeWithSymbols {
}
))
withinScope<Unit>($receiver = <this>.<get-typeRemapper>(), irTypeParametersContainer = <this>, fn = local fun <anonymous>() {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: Iterator<Pair<IrTypeParameter, IrTypeParameter>> = zip<IrTypeParameter, IrTypeParameter>($receiver = <this>.<get-typeParameters>(), other = other.<get-typeParameters>()).iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val tmp1_loop_parameter: Pair<IrTypeParameter, IrTypeParameter> = tmp0_iterator.next()
val thisTypeParameter: IrTypeParameter = tmp1_loop_parameter.component1()
val otherTypeParameter: IrTypeParameter = tmp1_loop_parameter.component2()
{ //BLOCK
{ // BLOCK
mapTo<IrType, IrType, MutableList<IrType>>($receiver = otherTypeParameter.<get-superTypes>(), destination = thisTypeParameter.<get-superTypes>(), transform = local fun <anonymous>(it: IrType): IrType {
return <this>.<get-typeRemapper>().remapType(type = it)
}
@@ -1,5 +1,5 @@
fun box(): String {
val obj: <no name provided> = { //BLOCK
val obj: <no name provided> = { // BLOCK
local class <no name provided> {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
+1 -1
View File
@@ -12,7 +12,7 @@ class Some {
init {
when {
less(arg0 = <this>.<get-foo>(), arg1 = 0) -> { //BLOCK
less(arg0 = <this>.<get-foo>(), arg1 = 0) -> { // BLOCK
<this>.<set-foo>(<set-?> = 0)
}
}
@@ -60,7 +60,7 @@ fun foo(candidate: Candidate) {
when {
me is FirCallableMemberDeclaration<*> -> EQEQ(arg0 = me /*as FirCallableMemberDeclaration<out FirCallableMemberDeclaration<*>> */.<get-symbol>(), arg1 = null).not()
true -> false
} -> { //BLOCK
} -> { // BLOCK
}
}
}
@@ -3,7 +3,7 @@ private const val BACKSLASH: Char
private get
private fun Reader.nextChar(): Char? {
return { //BLOCK
return { // BLOCK
val tmp0_safe_receiver: Int? = takeUnless<Int>($receiver = <this>.read(), predicate = local fun <anonymous>(it: Int): Boolean {
return EQEQ(arg0 = it, arg1 = -1)
}
@@ -20,9 +20,9 @@ fun Reader.consumeRestOfQuotedSequence(sb: StringBuilder, quote: Char) {
while (when {
EQEQ(arg0 = ch, arg1 = null).not() -> EQEQ(arg0 = ch, arg1 = quote).not()
true -> false
}) { //BLOCK
}) { // BLOCK
when {
EQEQ(arg0 = ch, arg1 = <get-BACKSLASH>()) -> { //BLOCK
EQEQ(arg0 = ch, arg1 = <get-BACKSLASH>()) -> { // BLOCK
val tmp0_safe_receiver: Char? = nextChar($receiver = <this>)
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
+1 -1
View File
@@ -1,7 +1,7 @@
fun outer() {
var x: Int = 0
local fun local() {
{ //BLOCK
{ // BLOCK
val tmp0: Int = x
x = tmp0.inc()
tmp0
@@ -2,12 +2,12 @@ fun box(): String {
val a: DoubleArray = TODO("IrConstructorCall")
val x: DoubleIterator = a.iterator()
var i: Int = 0
while (x.hasNext()) { //BLOCK
while (x.hasNext()) { // BLOCK
when {
ieee754equals(arg0 = a.get(index = i), arg1 = x.next()).not() -> return "Fail " +
i
}
{ //BLOCK
{ // BLOCK
val tmp0: Int = i
i = tmp0.inc()
tmp0
+7 -7
View File
@@ -7,12 +7,12 @@ fun two(): Int {
}
fun test1(): Int {
while (true) { //BLOCK
{ //BLOCK
while (true) { // BLOCK
{ // BLOCK
val tmp0_subject: Int = one()
when {
EQEQ(arg0 = tmp0_subject, arg1 = 1) -> { //BLOCK
{ //BLOCK
EQEQ(arg0 = tmp0_subject, arg1 = 1) -> { // BLOCK
{ // BLOCK
val tmp1_subject: Int = two()
when {
EQEQ(arg0 = tmp1_subject, arg1 = 2) -> return 2
@@ -26,11 +26,11 @@ fun test1(): Int {
}
fun test2(): Int {
while (true) { //BLOCK
{ //BLOCK
while (true) { // BLOCK
{ // BLOCK
val tmp0_subject: Int = one()
when {
EQEQ(arg0 = tmp0_subject, arg1 = 1) -> { //BLOCK
EQEQ(arg0 = tmp0_subject, arg1 = 1) -> { // BLOCK
val tmp1_subject: Int = two()
when {
EQEQ(arg0 = tmp1_subject, arg1 = 2) -> return 2
@@ -38,7 +38,7 @@ private fun CoroutineScope.asFairChannel(flow: Flow<*>): ReceiveChannel<Any> {
return produce<Any>($receiver = <this>, block = local suspend fun ProducerScope<Any>.<anonymous>() {
val channel: ChannelCoroutine<Any> = <this>.<get-channel>() as ChannelCoroutine<Any>
collect<Any?>($receiver = flow, action = local suspend fun <anonymous>(value: Any?) {
return channel.sendFair(element = { //BLOCK
return channel.sendFair(element = { // BLOCK
val tmp0_elvis_lhs: Any? = value
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> TODO("IrConstructorCall")
@@ -54,7 +54,7 @@ private fun CoroutineScope.asFairChannel(flow: Flow<*>): ReceiveChannel<Any> {
private fun CoroutineScope.asChannel(flow: Flow<*>): ReceiveChannel<Any> {
return produce<Any>($receiver = <this>, block = local suspend fun ProducerScope<Any>.<anonymous>() {
collect<Any?>($receiver = flow, action = local suspend fun <anonymous>(value: Any?) {
return <this>.<get-channel>().send(e = { //BLOCK
return <this>.<get-channel>().send(e = { // BLOCK
val tmp0_elvis_lhs: Any? = value
when {
EQEQ(arg0 = tmp0_elvis_lhs, arg1 = null) -> TODO("IrConstructorCall")
@@ -81,7 +81,7 @@ class P<P1 : Any?, P2 : Any?> {
}
val <T : Any?> Value<T, CR<T>>.additionalText: P<T, T> /* by */
field = { //BLOCK
field = { // BLOCK
local class <no name provided> : IDelegate1<Value<Any?, CR<Any?>>, P<Any?, Any?>> {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -98,7 +98,7 @@ val <T : Any?> Value<T, CR<T>>.additionalText: P<T, T> /* by */
}
private val Value<Any?, CR<Any?>>.deepO: Any? /* by */
field = { //BLOCK
field = { // BLOCK
local class <no name provided> : IDelegate1<Value<Any?, CR<Any?>>, Any?> {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -131,7 +131,7 @@ val <T : Any?> Value<T, CR<T>>.additionalText: P<T, T> /* by */
}
private val Value<Any?, CR<Any?>>.deepK: Any? /* by */
field = { //BLOCK
field = { // BLOCK
local class <no name provided> : IDelegate1<Value<Any?, CR<Any?>>, Any?> {
constructor() /* primary */ {
TODO("IrDelegatingConstructorCall")
@@ -2,24 +2,24 @@ fun use(s: P) {
}
fun testForInListUnused() {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: MutableIterator<@NotNull(...) @EnhancedNullability P> = listOfNotNull() /*!! List<@NotNull(...) @EnhancedNullability P> */ /*as MutableList<*> */.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val x: @NotNull(...) @EnhancedNullability P = tmp0_iterator.next()
{ //BLOCK
{ // BLOCK
}
}
}
}
fun testForInListDestructured() {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: MutableIterator<@NotNull(...) @EnhancedNullability P> = listOfNotNull() /*!! List<@NotNull(...) @EnhancedNullability P> */ /*as MutableList<*> */.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val tmp1_loop_parameter: @NotNull(...) @EnhancedNullability P = tmp0_iterator.next()
val x: Int = tmp1_loop_parameter /*!! @NotNull(...) P */.component1()
val y: Int = tmp1_loop_parameter /*!! @NotNull(...) P */.component2()
{ //BLOCK
{ // BLOCK
}
}
}
@@ -27,28 +27,28 @@ fun testForInListDestructured() {
fun testDesugaredForInList() {
val iterator: MutableIterator<@NotNull(...) @EnhancedNullability P> = listOfNotNull() /*!! List<@NotNull(...) @EnhancedNullability P> */ /*as MutableList<*> */.iterator()
while (iterator.hasNext()) { //BLOCK
while (iterator.hasNext()) { // BLOCK
val x: @NotNull(...) P = iterator.next() /*!! @NotNull(...) P */
}
}
fun testForInArrayUnused(j: J) {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: Iterator<@EnhancedNullability P> = j.arrayOfNotNull() /*!! Array<out @EnhancedNullability P> */ /*as Array<@EnhancedNullability P> */.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val x: @EnhancedNullability P = tmp0_iterator.next()
{ //BLOCK
{ // BLOCK
}
}
}
}
fun testForInListUse() {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: MutableIterator<@NotNull(...) @EnhancedNullability P> = listOfNotNull() /*!! List<@NotNull(...) @EnhancedNullability P> */ /*as MutableList<*> */.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val x: @NotNull(...) @EnhancedNullability P = tmp0_iterator.next()
{ //BLOCK
{ // BLOCK
use(s = x /*!! @NotNull(...) P */)
use(s = x)
}
@@ -57,11 +57,11 @@ fun testForInListUse() {
}
fun testForInArrayUse(j: J) {
{ //BLOCK
{ // BLOCK
val tmp0_iterator: Iterator<@EnhancedNullability P> = j.arrayOfNotNull() /*!! Array<out @EnhancedNullability P> */ /*as Array<@EnhancedNullability P> */.iterator()
while (tmp0_iterator.hasNext()) { //BLOCK
while (tmp0_iterator.hasNext()) { // BLOCK
val x: @EnhancedNullability P = tmp0_iterator.next()
{ //BLOCK
{ // BLOCK
use(s = x /*!! P */)
use(s = x)
}