More cases supported for inline functions: namespace level functions with parameters (not blocks)
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
package foo
|
||||
|
||||
fun box() : Boolean {
|
||||
if (myInlineFun(3, 2) != 1) {
|
||||
return false;
|
||||
}
|
||||
if (myInlineFun(100, -100) != 200) {
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
inline fun myInlineFun(l : Int, r : Int) = l - r
|
||||
Reference in New Issue
Block a user