Often I face following situation: suppose I have these three functions
def firstFn: Int = ... def secondFn(b: Int): Long = ... def thirdFn(x: Int, y: Long, z:
Stick with the original form:
def calculate(a: Long) = { val first = firstFn val second = secondFn(first) thirdFn(first, second, second + a) }
It's concise and clear, even to Java developers. It's roughly equivalent to let, just without limiting the scope of the names.