In the code below:
final int a; a=2; byte b=a;
Why am I getting this error? Is a final compile time variable a constant constant and, therefore, implicitly tapers to a byte at the time of assignment?
In other words, the code not shown above is equivalent:
final int a=2; byte b=a;
java expression constants compile-time-constant
paidedly Jun 11 '15 at 15:33 2015-06-11 15:33
source share