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 183340 Details for
Bug 330435
[1.4][1.5][compiler] Wrong handling of parameterized methods in 1.4 mode with generified JDK
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Add disable regression test
patch_330435.txt (text/plain), 2.68 KB, created by
Olivier Thomann
on 2010-11-17 15:18:40 EST
(
hide
)
Description:
Add disable regression test
Filename:
MIME Type:
Creator:
Olivier Thomann
Created:
2010-11-17 15:18:40 EST
Size:
2.68 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.core.tests.compiler >Index: src/org/eclipse/jdt/core/tests/compiler/regression/MethodVerifyTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/MethodVerifyTest.java,v >retrieving revision 1.212 >diff -u -r1.212 MethodVerifyTest.java >--- src/org/eclipse/jdt/core/tests/compiler/regression/MethodVerifyTest.java 7 Nov 2010 02:30:20 -0000 1.212 >+++ src/org/eclipse/jdt/core/tests/compiler/regression/MethodVerifyTest.java 17 Nov 2010 20:18:12 -0000 >@@ -27,7 +27,7 @@ > > public class MethodVerifyTest extends AbstractComparableTest { > static { >-// TESTS_NAMES = new String[] { "test329584_2", "test329584_3" }; >+// TESTS_NAMES = new String[] { "test330435" }; > // TESTS_NUMBERS = new int[] { 213 }; > // TESTS_RANGE = new int[] { 190, -1}; > } >@@ -11272,4 +11272,55 @@ > compilerOptions14, > null); > } >+//https://bugs.eclipse.org/bugs/show_bug.cgi?id=330435 >+public void _test330435() { >+ Map compilerOptions15 = getCompilerOptions(); >+ compilerOptions15.put(JavaCore.COMPILER_CODEGEN_TARGET_PLATFORM, CompilerOptions.VERSION_1_5); >+ compilerOptions15.put(JavaCore.COMPILER_COMPLIANCE, JavaCore.VERSION_1_5); >+ compilerOptions15.put(JavaCore.COMPILER_SOURCE, JavaCore.VERSION_1_5); >+ this.runConformTest( >+ new String[] { >+ "A.java", >+ "public class A {\n" + >+ " public static <T> B<T> asList(T... tab) {\n" + >+ " return null;\n" + >+ " }\n" + >+ "}", >+ "B.java", >+ "public interface B<V> {\n" + >+ " <T> T[] toArray(T[] tab);\n" + >+ "}\n", >+ }, >+ "", >+ null, >+ true, >+ null, >+ compilerOptions15, >+ null); >+ // >+ Map compilerOptions14 = getCompilerOptions(); >+ compilerOptions14.put(JavaCore.COMPILER_CODEGEN_TARGET_PLATFORM, JavaCore.VERSION_1_2); >+ compilerOptions14.put(JavaCore.COMPILER_COMPLIANCE, JavaCore.VERSION_1_4); >+ compilerOptions14.put(JavaCore.COMPILER_SOURCE, JavaCore.VERSION_1_3); >+ compilerOptions14.put(JavaCore.COMPILER_PB_UNNECESSARY_TYPE_CHECK, JavaCore.IGNORE); >+ this.runNegativeTest( >+ new String[] { >+ "X.java", >+ "public class X {\n" + >+ " String[] foo(Object[] args) {\n" + >+ " String[] a = A.asList(args).toArray(new String[0]);\n" + >+ " return a;\n" + >+ " }\n" + >+ "}", >+ }, >+ "----------\n" + >+ "1. ERROR in X.java (at line 3)\n" + >+ " String[] a = A.asList(args).toArray(new String[0]);\n" + >+ " ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n" + >+ "Type mismatch: cannot convert from Object[] to String[]\n" + >+ "----------\n", >+ null, >+ false, >+ compilerOptions14); >+} > }
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 330435
:
183340
|
183444
|
183460