mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-08 00:21:26 +00:00
Fast version for POP backward propagation (without SourceInterpreter)
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
inline fun inlineFunVoid(f: () -> Unit): Unit {
|
||||
return f()
|
||||
}
|
||||
|
||||
inline fun coercedToUnit() {
|
||||
inlineFunVoid {
|
||||
var aa = 1
|
||||
++aa
|
||||
}
|
||||
}
|
||||
|
||||
inline fun dup(f: () -> Unit): Unit {
|
||||
f()
|
||||
f()
|
||||
}
|
||||
|
||||
fun test() {
|
||||
dup { dup { dup { dup { dup {
|
||||
dup { dup {
|
||||
coercedToUnit()
|
||||
}}}}}
|
||||
}}
|
||||
}
|
||||
|
||||
// 3 POP
|
||||
Reference in New Issue
Block a user