Community
Participate
Working Groups
BETA_JAVA8: The following program fails to compile. We get: Type mismatch: cannot convert from Class<TC> to Class<? extends Annotation> // -- import java.lang.annotation.Annotation; import java.lang.annotation.ElementType; import java.lang.annotation.Target; @R(TC.class) @Target(ElementType.TYPE_PARAMETER) @interface T { } interface I<@T K> { } @Deprecated @interface TC { } @Target(ElementType.ANNOTATION_TYPE) @interface R { Class<? extends Annotation> value(); } I have released a test TypeAnnotationTest.testForwardReference() encoding the wrong behavior - The test needs to fixed along with the problem.
This problem is not related to JEP120 per se, but I think we will hit in that context as users try the feature. Jesper, thanks for taking a look at this.
*** Bug 419821 has been marked as a duplicate of this bug. ***
Sorry for grabbing this one, As we are preparing for an early access release early next week, I wanted to close out on a bunch of items. Thanks. Fix and tests released here: http://git.eclipse.org/c/jdt/eclipse.jdt.core.git/commit/?h=BETA_JAVA8&id=2a851009aaa407c5e4c32cb132dfb84271f2e7fd
This bug seems to be present at JDT 4.4 M7 compiling with JDK 1.7.55 --- The annotation: @Retention(RetentionPolicy.RUNTIME) @Target(ElementType.TYPE) public @interface XmlReadTransformer { @SuppressWarnings("rawtypes") Class<? extends XmlReadCustomTransformer> using(); } --- The interface public static interface XmlWriteCustomTransformer { public String xmlFromBean(Object bean); } --- The implementation public class MyTransformer implements XmlWriteCustomTransformer { public String xmlFromBean(Object bean) { .... } } --- The place where it does NOT compile: @XmlReadTransformer(using=MyTransformer.class) <<<<< COMPILE ERROR!! public class MyTransformedType { .... }