245 ste(outer, VALID, VALID, true, MAIN_SNIPPET)); |
245 ste(outer, VALID, VALID, true, MAIN_SNIPPET)); |
246 assertActiveKeys(); |
246 assertActiveKeys(); |
247 } |
247 } |
248 |
248 |
249 public void classesIgnoredModifiers() { |
249 public void classesIgnoredModifiers() { |
250 assertDeclareWarn1("public interface A { }", |
250 assertEval("public interface A { }"); |
251 new ExpectedDiagnostic("jdk.eval.warn.illegal.modifiers", 0, 6, 0, -1, -1, Diagnostic.Kind.WARNING)); |
|
252 assertDeclareWarn1("static class B implements A { }", |
251 assertDeclareWarn1("static class B implements A { }", |
253 new ExpectedDiagnostic("jdk.eval.warn.illegal.modifiers", 0, 6, 0, -1, -1, Diagnostic.Kind.WARNING)); |
252 new ExpectedDiagnostic("jdk.eval.warn.illegal.modifiers", 0, 6, 0, -1, -1, Diagnostic.Kind.WARNING)); |
254 assertDeclareWarn1("final interface C extends A { }", |
253 assertDeclareWarn1("final interface C extends A { }", |
255 new ExpectedDiagnostic("jdk.eval.warn.illegal.modifiers", 0, 5, 0, -1, -1, Diagnostic.Kind.WARNING)); |
254 new ExpectedDiagnostic("jdk.eval.warn.illegal.modifiers", 0, 5, 0, -1, -1, Diagnostic.Kind.WARNING)); |
256 assertDeclareWarn1("protected enum D implements C { }", |
|
257 new ExpectedDiagnostic("jdk.eval.warn.illegal.modifiers", 0, 9, 0, -1, -1, Diagnostic.Kind.WARNING)); |
|
258 assertActiveKeys(); |
255 assertActiveKeys(); |
259 } |
256 } |
260 |
257 |
261 public void ignoreModifierSpaceIssue() { |
258 public void ignoreModifierSpaceIssue() { |
262 assertEval("interface I { void f(); } "); |
259 assertEval("interface I { void f(); } "); |