Only use the former when the body is a single, short expression? I'm not sure what kind of conventions you're looking for.
i
iex
06/20/2018, 1:49 PM
I explained it in the next message...
but here again, the differentiation is between when you want to return something / do something with the return value and perform only side effects
and at least in scala there used to be a convention that when you only want to perform side effects, the method was considered a "procedure" and put between
{}
- whether it was long or a one liner
so I wanted to know if there's something similar in Kotlin but it doesn't seem to be the case
even in Scala this convention seems to be outdated