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 37043 Details for
Bug 133440
[1.5][compiler] JDT allows annotation to have a null default
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Corresponding regression test
patch_133440_tests.txt (text/plain), 1.58 KB, created by
Olivier Thomann
on 2006-03-27 23:20:51 EST
(
hide
)
Description:
Corresponding regression test
Filename:
MIME Type:
Creator:
Olivier Thomann
Created:
2006-03-27 23:20:51 EST
Size:
1.58 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.core.tests.compiler >Index: src/org/eclipse/jdt/core/tests/compiler/regression/AnnotationTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/AnnotationTest.java,v >retrieving revision 1.144 >diff -u -r1.144 AnnotationTest.java >--- src/org/eclipse/jdt/core/tests/compiler/regression/AnnotationTest.java 6 Mar 2006 14:40:40 -0000 1.144 >+++ src/org/eclipse/jdt/core/tests/compiler/regression/AnnotationTest.java 28 Mar 2006 04:20:24 -0000 >@@ -38,7 +38,7 @@ > // All specified tests which do not belong to the class are skipped... > static { > // TESTS_NAMES = new String[] { "test127" }; >-// TESTS_NUMBERS = new int[] { 188 }; >+// TESTS_NUMBERS = new int[] { 196 }; > // TESTS_RANGE = new int[] { 169, 180 }; > } > >@@ -6413,4 +6413,23 @@ > "Zork cannot be resolved to a type\n" + > "----------\n"); > } >+//https://bugs.eclipse.org/bugs/show_bug.cgi?id=133440 >+public void test196() { >+ this.runNegativeTest( >+ new String[] { >+ "X.java", >+ "public @interface X {\n" + >+ " enum MyEnum {\n" + >+ " VAL_1, VAL_2\n" + >+ " }\n" + >+ " public MyEnum theValue() default null;\n" + >+ "}" >+ }, >+ "----------\n" + >+ "1. ERROR in X.java (at line 5)\n" + >+ " public MyEnum theValue() default null;\n" + >+ " ^^^^\n" + >+ "The value for annotation attribute X.theValue must be a constant expression\n" + >+ "----------\n"); >+} > }
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 133440
:
37042
| 37043 |
37224