This syntax is officially deprecated.
Instead one must write explicitly:
Meaning that the value of x.length is discarded and the function returns Unit (or () if you prefer) instead.
I'd like to stress out that this is deprecated since Oct 29, 2013 (https://github.com/scala/scala/pull/3076/), but the warning only shows up if you compile with the -Xfuture flag.
We should turn on the -Xfuture flag, and fix this and any other deprecations that come up.
We may want to write a sed-script or other automation. I have generally preferred the now-deprecated style in my code, so there are many many cases.