More proper code to check if lambda is inlined. Parameter of inline function can be annotated with "noInline".
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
fun f(a: Int): Int {
|
||||
if (a < 5) {
|
||||
run1(fun (): Int {
|
||||
<caret>return 1
|
||||
})
|
||||
}
|
||||
return 2
|
||||
}
|
||||
|
||||
inline public fun <T> run1(noinline f: () -> T): T { }
|
||||
|
||||
//HIGHLIGHTED: return 1
|
||||
Reference in New Issue
Block a user