mirror of
https://github.com/eclipse-aspectj/aspectj.git
synced 2024-08-14 14:11:27 +02:00
15 lines
380 B
Java
15 lines
380 B
Java
// modeled on jacks 16.2.7-final-4: A final variable
|
|
// must be definitely unassigned if it
|
|
// is to be assigned inside an if (false) block.
|
|
// if false is no protection for evildoers
|
|
|
|
public class UnderIfFalse {
|
|
static int foo() { return 0; }
|
|
static final int val = foo();
|
|
public static void main(String[] args) {
|
|
if (false) {
|
|
val = 1;
|
|
}
|
|
}
|
|
}
|