Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 219853 Details for
Bug 386356
Type mismatch error with annotations and generics
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
fix under test
clipboard.txt (text/plain), 3.52 KB, created by
Stephan Herrmann
on 2012-08-14 07:50:45 EDT
(
hide
)
Description:
fix under test
Filename:
MIME Type:
Creator:
Stephan Herrmann
Created:
2012-08-14 07:50:45 EDT
Size:
3.52 KB
patch
obsolete
>diff --git a/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/AnnotationTest.java b/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/AnnotationTest.java >index c5a75b4..4dd61ee 100644 >--- a/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/AnnotationTest.java >+++ b/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/AnnotationTest.java >@@ -48,7 +48,7 @@ > // Static initializer to specify tests subset using TESTS_* static variables > // All specified tests which do not belong to the class are skipped... > static { >-// TESTS_NAMES = new String[] { "testBug384663" }; >+ TESTS_NAMES = new String[] { "testBug386356" }; > // TESTS_NUMBERS = new int[] { 297 }; > // TESTS_RANGE = new int[] { 294, -1 }; > } >@@ -10637,4 +10637,64 @@ > }; > runConformTest(testFiles); > } >+ >+// Bug 386356 - Type mismatch error with annotations and generics >+// test case from comment 9 >+public void testBug386356_1() { >+ runConformTest( >+ new String[] { >+ "p/X.java", >+ "package p;\n" + >+ "import javax.xml.bind.annotation.adapters.XmlAdapter;\n" + >+ "public abstract class X extends XmlAdapter<String,X> {\n" + >+ "}", >+ >+ "p/package-info.java", >+ "@XmlJavaTypeAdapters({ @XmlJavaTypeAdapter(value = X.class, type = X.class) })\n" + >+ "package p;\n" + >+ "import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; \n" + >+ "import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapters;" >+ >+ }); >+} >+ >+//Bug 386356 - Type mismatch error with annotations and generics >+//test case from comment 6 >+public void testBug386356_2() { >+ runConformTest( >+ new String[] { >+ "com/ermahgerd/Ermahgerd.java", >+ "package com.ermahgerd;\n" + >+ "\n" + >+ "public class Ermahgerd {\n" + >+ "}", >+ >+ "com/ermahgerd/package-info.java", >+ "@XmlJavaTypeAdapters({ @XmlJavaTypeAdapter(value = ErmahgerdXmlAdapter.class, type = Ermahgerd.class) })\n" + >+ "package com.ermahgerd;\n" + >+ "import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;\n" + >+ "import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapters;", >+ >+ "com/ermahgerd/ErmahgerdXmlAdapter.java", >+ "package com.ermahgerd;\n" + >+ "\n" + >+ "import javax.xml.bind.annotation.adapters.XmlAdapter;\n" + >+ "\n" + >+ "public class ErmahgerdXmlAdapter extends XmlAdapter<String,Ermahgerd> {\n" + >+ "\n" + >+ " @Override\n" + >+ " public String marshal(Ermahgerd arg0) throws Exception {\n" + >+ " // TODO Auto-generated method stub\n" + >+ " return null;\n" + >+ " }\n" + >+ "\n" + >+ " @Override\n" + >+ " public Ermahgerd unmarshal(String arg0) throws Exception {\n" + >+ " // TODO Auto-generated method stub\n" + >+ " return null;\n" + >+ " }\n" + >+ "}" >+ >+ }); >+} > } >diff --git a/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/lookup/SourceTypeBinding.java b/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/lookup/SourceTypeBinding.java >index a8fbc59..096b544 100644 >--- a/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/lookup/SourceTypeBinding.java >+++ b/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/lookup/SourceTypeBinding.java >@@ -1100,8 +1100,6 @@ > this.modifiers |= ClassFileConstants.AccDeprecated; > } > } >- if (CharOperation.equals(this.sourceName, TypeConstants.PACKAGE_INFO_NAME)) >- getAnnotationTagBits(); // initialize > } > > // ensure the receiver knows its hierarchy & fields/methods so static imports can be resolved correctly
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 386356
:
219697
| 219853