[JSR308] Custom annotations?

Tom Ball Tom.Ball at Sun.COM
Sun Feb 10 17:52:32 EST 2008


Richard Gomes wrote:
> Hi Mike,
> 
> Thank you for your directions.
> 
> It should be very convenient to detect that ...
> 
> @Rate double rate = 1.0;
> @Volatility double vol = rate;
> 
> .... cannot compile because the variables are semantically different, 
> nevertheless both are represented internally as floating point numbers.

It had better compile, as annotations aren't supposed to change 
compilation behavior.  Your error detector could certainly flag it as an 
error, however.

Tom



More information about the JSR308 mailing list