IR: create more temporary vals when optimizing tailrec calls
This is needed so that SharedVariablesLowering doesn't get confused, and SharedVariablesLowering should run after TailrecLowering to properly optimize tailrec calls in inline lambdas.
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
// IGNORE_BACKEND: JS_IR, WASM
|
||||
|
||||
interface IFoo {
|
||||
fun foo(): String
|
||||
}
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
// IGNORE_BACKEND: JS_IR, WASM
|
||||
|
||||
interface IFoo {
|
||||
fun foo(): String
|
||||
}
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
// IGNORE_BACKEND: JS_IR
|
||||
|
||||
tailrec fun tailrecDefault(fake: Int, fn: () -> String = { "OK" }): String {
|
||||
return if (fake == 0)
|
||||
tailrecDefault(1)
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
// IGNORE_BACKEND: WASM
|
||||
// IGNORE_BACKEND: JS_IR
|
||||
|
||||
class C
|
||||
|
||||
fun box(): String =
|
||||
|
||||
Reference in New Issue
Block a user