Pattern Matching for instanceof (Preview 2)
brian.goetz at oracle.com
Thu Feb 6 23:00:40 UTC 2020
> var is not really any, it's an inferred type pattern.
> '_' is any, no ?
Conveniently, an inferred type pattern _is_ an any pattern. (See the
explanation in the recent discussion on nullity, where this fell out
nicely.) So semantically a var pattern is an any pattern. Whether or
not we want an explicit any pattern is a separate question.
More information about the amber-spec-experts