pawel.urban
11/03/2016, 8:19 AMprivate fun doSomeAction() = {
// Very important code here.
}
private fun doSomeAction() {
// Very important code here.
}
Trick or treat 🙂 It’s hard to see an error here. In the first example it returns () -> Unit in the second just an Unit. Maybe it would be worth considering if the compiler/lint would warn us about the first scenario? Only on case when there is no assignment in the function usage.