[JSR308] Postfix syntax for type annotations

Neal Gafter gafter at google.com
Sun Feb 25 11:10:57 EST 2007

On 2/25/07, Michael Ernst <mernst at csail.mit.edu> wrote:
> Neal-
> > > Actually, the draft proposal says that the meaning is *unambiguous* in
> > > those cases.  (A previous version incorrectly stated that the syntax
> is
> > > ambiguous.)
> >
> > I quote (emphasis mine):
> > [snipped]
> You are quoting from an old draft.  As my text indicated, the previous
> version was not ideally worded.  Criticism of a non-current version is of
> limited value.
> > Here's what I find at the end of section 3.1:
> > [snipped]
> Again, you are reading an old version, not the current one, so you are in
> the wrong section entirely.
> > The spec currently takes the approach of
> > specifying annotations for each context separately
> An earlier version of the draft was unclear on this point.  The current
> one
> is more straightforward:
>   Our system uses a simple prefix syntax for type annotations: the
>   annotation appears before the type, as in @NonNull String. There are two
>   exceptions to this general rule: the syntax for arrays and the syntax
> for
>   method receivers (see below).
>   The following list gives examples of how annotations are written in the
>   source.
>   ...
> Let's try to keep our discussions focused on the present.  It is
> disappointing to waste breath on a stale version of the document,
> particularly because I updated the draft on the website last night, before
> the current flurry of messages, and notified this list of that update.  If
> you don't want to reread the whole document, you can find a record of
> changes to it at http://pag.csail.mit.edu/jsr308/changes.html.

I commented on the most current html version, by following the link you
provided. In any case, I don't see any changes that remove the ambiguity,
only commentary dismissing it.

In order to clarify the ambiguity issue, can you please include in the
specification the proposed grammar changes? Then we can apply the usual
grammar analysis techniques to see if there is an ambiguity or not.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.csail.mit.edu/pipermail/jsr308/attachments/20070225/bc837b45/attachment.html

More information about the JSR308 mailing list