class MyClass { public void aMethod() { final int i = 0; static class InnerClass { public void print() { System.out.println(i); } } } }
Illegal modifier for the local class InnerClass; only abstract or final is permitted