mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-18 09:34:34 +07:00
[java] improves "unsupported language level" message (IDEA-168859)
This commit is contained in:
+5
-5
@@ -1,14 +1,14 @@
|
||||
class Test {
|
||||
interface I {
|
||||
<error descr="Extension methods are not supported at this language level">static void foo() {}</error>
|
||||
<error descr="Extension methods are not supported at language level '1.7'">static void foo() {}</error>
|
||||
}
|
||||
|
||||
abstract class IImpl implements I {}
|
||||
abstract static class IImpl implements I {}
|
||||
interface I2 extends I {}
|
||||
|
||||
{
|
||||
<error descr="Static interface method invocations are not supported at this language level">I.foo();</error>
|
||||
IImpl.<error descr="Static interface method invocations are not supported at this language level">foo</error>();
|
||||
I2.<error descr="Static interface method invocations are not supported at this language level">foo</error>();
|
||||
I.<error descr="Static interface method calls are not supported at language level '1.7'">foo</error>();
|
||||
IImpl.<error descr="Static interface method calls are not supported at language level '1.7'">foo</error>();
|
||||
I2.<error descr="Static interface method calls are not supported at language level '1.7'">foo</error>();
|
||||
}
|
||||
}
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
import java.io.Serializable;
|
||||
|
||||
class IntersectionTypeCast {
|
||||
void m(Runnable r) {
|
||||
Object o = <error descr="Intersection types in casts are not supported at language level '1.7'">(Runnable & Serializable)r</error>;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user