vgrechka
02/23/2017, 12:24 PMf
below doesn't compile, while h
does? Is it because of @kotlin.internal.InlineOnly
annotation on let
?
inline fun g(block: () -> Unit) = block()
fun f(): Int {
g {
return 123
}
} // Error: A 'return' expression is required...
fun h(): Int {
null.let {
return 123
}
}