Pattern Matching for instanceof (Preview 2)

Remi Forax forax at
Thu Feb 6 20:38:29 UTC 2020

[moved to amber-spec]

----- Mail original -----
> De: "jan lahoda" <jan.lahoda at>
> À: "amber-dev" <amber-dev at>
> Envoyé: Jeudi 6 Février 2020 21:18:52
> Objet: Pattern Matching for instanceof (Preview 2)

> Hi,
> Thanks to Gavin, Brian and Alex, there is a new draft JEP for Pattern
> Matching for instanceof (Preview 2):
> Any feedback on the JEP is more than welcome!
> Thanks,
>      Jan

so the difference with the previous preview is that deconstruction is added.

I see two questions:
- the grammar allows to mix var and non-var for a given reference type, i think that should only permitted if the non var is a deconstruction itself ?
- must the identifier of a pattern argument be the same name as the corresponding record component ?
  To be coherent with the fact that constructors requires the same names.


More information about the amber-spec-experts mailing list