[jdk16] RFR: 8254023: A module declaration is not allowed to be a target of an annotation that lacks an @Target meta-annotation
wmdietl at openjdk.java.net
Fri Dec 18 18:20:56 UTC 2020
On Wed, 16 Dec 2020 12:02:58 GMT, Guoxiong Li <github.com+13688759+lgxbslgx at openjdk.org> wrote:
> Hi all,
> This patch adds `names.MODULE` to `com.sun.tools.javac.comp.Check.dfltTargetMeta` to fix this issue. And it also adds some corresponding tests.
> The previous discussion is in https://github.com/openjdk/jdk/pull/622.
> Best Regards.
test/langtools/tools/javac/annotations/8254023/T8254023.java line 27:
> 25: * @test
> 26: * @bug 8254023
> 27: * @summary A module declaration is not allowed to be a target of an annotation that lacks an (at)Target meta-annotation
@lgxbslgx I'm confused by the "is not allowed". Isn't this testing that this is allowed without an error?
I realize that that is in the tile of JDK-8254023, but the resolution is to allow such annotations, right?
More information about the compiler-dev