Draft JEP: Keyword Management for the Java Language (original) (raw)
Remi Forax forax at univ-mlv.fr
Wed May 1 21:23:39 UTC 2019
- Previous message: Draft JEP: Keyword Management for the Java Language
- Next message: Draft JEP: Keyword Management for the Java Language
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
----- Mail original -----
De: "Alex Buckley" <alex.buckley at oracle.com> À: "jdk-dev" <jdk-dev at openjdk.java.net> Envoyé: Mercredi 1 Mai 2019 22:55:53 Objet: Re: Draft JEP: Keyword Management for the Java Language
On 5/1/2019 1:21 PM, Remi Forax wrote:
I think 'this' are also missing from {A}, Foo.this is a valid expression (while semantically invalid). Yes, and
Foo.this-day
is close enough toFoo::new-day
that both can be explained together (so we don't forget whythis
ended up in set A).For 'null', 'true' and 'false', there are also valid expression but invalid semantically, so following the same logic they should be in {A} and {B}.
in that case non-null is not a valid hyphenated keyword but it's a valid hyphenated keyword if contextual (as modifier for a field or a method). I think the JEP already takes reasonable care over
null
,true
, andfalse
. They're highlighted as literals rather than keywords early on, andnon-null
andeventually-true
are clearly marked as examples of hyphenated contextual keywords rather than hyphenated classic keywords. Later, the "formal" statement involving sets A and B is specifically about hyphenated classic keywords, so it doesn't advise onnon-null
at all. I could add constraints for hyphenated contextual keywords but this JEP is a policy/approach, not a spec, so I'm going to stop here; this has been a productive thread.
i agree.
Alex
Rémi
- Previous message: Draft JEP: Keyword Management for the Java Language
- Next message: Draft JEP: Keyword Management for the Java Language
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]