News for hackers. Stuff that matters.
Re:New language features since Java 8 to 17 by nikeee on Sunday October 24, 2021 @06:59PM (#28982727)
IMHO safe navigation only makes sense when the compiler is able to reason about nullability, meaning nullability is rooted in the type system. That's the case for Kotlin and not for Java.

Otherwise, you've got a high risk of developers inserting a ? to fix a bug, which only fixes the symptoms.

As of now, Optional#map seems to be the way to go.

There are no comments on this comment yet.