forbid native in interfaces (IDEA-140491)

This commit is contained in:
Anna Kozlova
2015-05-20 13:49:49 +02:00
parent f53bb94115
commit 2fc7821d06
3 changed files with 10 additions and 0 deletions
@@ -0,0 +1,5 @@
interface A {
default <error descr="Modifier 'native' not allowed here">native</error> void m(){}
static <error descr="Modifier 'native' not allowed here">native</error> void m1(){}
<error descr="Modifier 'native' not allowed here">native</error> void m2();
}
@@ -36,6 +36,7 @@ public class Interface8MethodsHighlightingTest extends LightCodeInsightFixtureTe
public void testStaticMethodCalls() { doTest(false, false); }
public void testStaticMethodCallsAndOverloadResolution() { doTest(false, false); }
public void testDefaultMethodOverrideEquivalentObject() { doTest(false, false); }
public void testModifierNativeInInterface() { doTest(false, false); }
public void testStaticMethods() { doTest(false, false); }
public void testFinalStaticDefaultMethods() { doTest(false, false); }
public void testIDEA122720() { doTest(false, false); }