mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-05-01 02:38:59 +07:00
This patch encapsulates the logic that checks if a used feature is annotated with PreviewFeature in its own visitor. The visitor now checks both PreviewFeature annotations with old and new packages. GitOrigin-RevId: f3ddc2a840b8c3a8bb4e1a731e2c208002a29fd4
19 lines
1.0 KiB
Java
19 lines
1.0 KiB
Java
import <error descr="Patterns in 'instanceof' are not supported at language level '9'">org.myorg.jdk.internal.javac.preview.FromPreview</error>;
|
|
import static <error descr="Patterns in 'instanceof' are not supported at language level '9'">org.myorg.jdk.internal.javac.preview.FromPreview</error>.f;
|
|
import static <error descr="Patterns in 'instanceof' are not supported at language level '9'">org.myorg.jdk.internal.javac.preview.FromPreview</error>.*;
|
|
import static <error descr="Class 'B' is in the default package">B</error>.g;
|
|
|
|
class Main {
|
|
static {
|
|
<error descr="Patterns in 'instanceof' are not supported at language level '9'">org.myorg.jdk.internal.javac.preview.FromPreview</error>.f();
|
|
<error descr="Patterns in 'instanceof' are not supported at language level '9'">f</error>();
|
|
<error descr="Text block literals are not supported at language level '9'">B</error>.g();
|
|
g();
|
|
}
|
|
}
|
|
|
|
@jdk.internal.javac.PreviewFeature(feature = jdk.internal.javac.PreviewFeature.Feature.TEXT_BLOCKS)
|
|
class B {
|
|
static void g() {}
|
|
}
|