Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

1234567891011121314151617181920
  1. public class InnerMembers {
  2. static class StaticI {
  3. static int x;
  4. static String foo() { return "foo"; }
  5. }
  6. class Inner {
  7. static final int CONST=10;
  8. static final int NOT_CONST=new Integer(10).intValue(); //ERR: non-constant static in inner
  9. static int x; //ERR: non-constant static in inner
  10. static String foo() { return "foo"; }//ERR: non-constant static in inner
  11. interface I {}//ERR: non-constant static in inner
  12. }
  13. public static void m() {
  14. class Inner {
  15. static final int CONST=10;
  16. static int x; //ERR: non-constant static in inner
  17. static String foo() { return "foo"; }//ERR: non-constant static in inner
  18. }
  19. }
  20. }