News for hackers. Stuff that matters.
Re:Can I get some reasons to use Java instead of Kotlin? by vips7L on Monday May 17, 2021 @11:38AM (#27184682)
I really think Goetz/the Java language people are waiting to see if nullable types actually pay off in C#/Kotlin first, like with every feature, before considering it.
Re:Can I get some reasons to use Java instead of Kotlin? by karmakaze on Monday May 17, 2021 @03:41PM (#27187471)
In other areas they're already trying. e.g.

  if (o instanceof SomeClass) {
    o.someClassMethod();
  }
Following this line of reasoning I could want to assign it to a local var:

  if (o instanceof SomeClass) {
    final var s = o;
    ...
  }
An analogous situation arises with null:

  if (o != null) {
    final var s = o;
    ...
  }
Making the type of `s` a non-null type of `o`s type.

The annoying thing with Java language development is that they just don't seem interested in rounding it out with consistency/completeness.