Fix FIR incremental compilation failure with inlines and lambdas

#KT-51546 fixed
This commit is contained in:
Ilya Chernikov
2022-03-05 18:27:25 +01:00
committed by teamcity
parent 8f1a2f4612
commit aa0386276d
13 changed files with 134 additions and 12 deletions
@@ -0,0 +1,11 @@
================ Step #1 =================
Cleaning output files:
out/production/module/META-INF/module.kotlin_module
out/production/module/usage/Usage.class
End of files
Compiling files:
src/usage.kt
End of files
Exit code: OK
------------------------------------------
@@ -0,0 +1,9 @@
package inline
private inline fun ps(): () -> String { val z = "Outer"; return { "OK" } }
internal inline fun test(s: () -> () -> String = ::ps) =
s()
val same = test()
@@ -0,0 +1,3 @@
package usage
fun other() {}
@@ -0,0 +1,7 @@
package usage
internal class Usage {
val inlined = inline.test()
val check = inline.same::class.java == inlined::class.java
}
@@ -0,0 +1,7 @@
package usage
internal class Usage {
private val inlined = inline.test()
private val check = inline.same::class.java == inlined::class.java
}