MethodParameters attributes in v51 classfiles
Liam Miller-Cushon
cushon at google.com
Wed Nov 9 00:31:02 UTC 2016
If -parameters is passed, javac will write MethodParameters attributes when
source/target < 8. It also reports -Xlint:classfile warnings about
MethodParameters attributes in < v52 classfiles:
class X {
void f(int a) {}
}
class Y {
X x;
}
$ javac -source 7 -target 7 -parameters X.java
$ javac -Xlint:classfile -sourcepath : Y.java
./X.class: warning: [classfile] MethodParameters attribute introduced in
version 52.0 class files is ignored in version 51.0 class files
Is that deliberate? I expected it to either not write the attribute for old
classfile versions, or not warn about it.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/compiler-dev/attachments/20161108/2d8cbef4/attachment.html>
More information about the compiler-dev
mailing list