Re:JEP 286: Local-Variable Type Inference
by cballard on Thursday March 10, 2016 @03:15PM
(#11261940)
Making the immutable version the same length as (or preferably, shorter than, e.g. Rust) the mutable version encourages the use of immutability.
Re:JEP 286: Local-Variable Type Inference
by skippytheroo on Friday March 11, 2016 @01:02AM
(#11264915)
val is a much better idea. Final is longer to type, in many cases as long as just declaring the type. We should be encouraging immutability not discouraging it by making it more verbose than necessary.
I like the approach mentioned of just reusing final for immutability.