-
Bug
-
Resolution: Fixed
-
P4
-
repo-valhalla
-
generic
-
generic
The following code compiles fine:
public primitive class X implements Cloneable {
public static void main(String [] args) {
}
}
but when run fails with:
Error: LinkageError occurred while loading main class X
java.lang.ClassFormatError: class: X - Inline Types do not support Cloneable
JEP 401 states:
(Possibly) The class does not implement Cloneable or declare a clone() method.
Javac implements the latter clause but not the former.
public primitive class X implements Cloneable {
public static void main(String [] args) {
}
}
but when run fails with:
Error: LinkageError occurred while loading main class X
java.lang.ClassFormatError: class: X - Inline Types do not support Cloneable
JEP 401 states:
(Possibly) The class does not implement Cloneable or declare a clone() method.
Javac implements the latter clause but not the former.