Hacker News new | ask | show | jobs
by karmakaze 1865 days ago
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.