[JSR308] Full list of locations for annotations

Eugene Kuleshov eu at javatx.org
Sun Feb 25 10:41:57 EST 2007


  This is related to the annotation locations and especially 
expressions/literals. While back it been pointed out, that expressions 
can be annotated using annotation on cast. I.e.

  String sql = (@Language("SQL") String) "select * from foo";

  I wonder it would make sense to allow a shorthand syntax for this:

  String sql = (@Language("SQL")) "select * from foo";

  regards,
  Eugene


Michael Ernst wrote:
> We have made good progress on discussing details for certain annotations,
> but I would like to look at the bigger picture, and in particular to
> discuss whether there are any other annotation locations that we should
> consider.  (However, I do *not* want to discuss the merits of these
> locations now -- I only want to get them on the table, so that we remember
> to discuss them, individually, at the proper time.)
>
> Here is the current status of our deliberations, as I understand it.
> I've also put this in the "Open issues" list at
>   http://pag.csail.mit.edu/jsr308/#Open_issues
>
> Definitely supported:
>  * types
> Possibly supported (under current discussion)
>  * local variables
>  * each level of an array
>  * statements
> Definitely not supported:
>  * expressions
>  * blocks and/or loops (as a restricted special case of statements)
>  * partial constructs (such as only the body of a loop)
>
> If there are other locations we should put on the "Possibly supported" list
> (and then eventually move to one of the other categories), please raise it.
> For now, let's focus on the big picture, and we can dive into specific
> details about the candidate locations later.
>
>                     -Mike
>
> _______________________________________________
> JSR308 mailing list
> JSR308 at lists.csail.mit.edu
> https://lists.csail.mit.edu/mailman/listinfo/jsr308
>   




More information about the JSR308 mailing list