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 76784 Details for
Bug 200724
[compiler] Assignment with no effect undetected
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Regression tests
patch_200724_tests.txt (text/plain), 1.91 KB, created by
Olivier Thomann
on 2007-08-23 11:48:49 EDT
(
hide
)
Description:
Regression tests
Filename:
MIME Type:
Creator:
Olivier Thomann
Created:
2007-08-23 11:48:49 EDT
Size:
1.91 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.core.tests.compiler >Index: src/org/eclipse/jdt/core/tests/compiler/regression/AssignmentTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/AssignmentTest.java,v >retrieving revision 1.40 >diff -u -r1.40 AssignmentTest.java >--- src/org/eclipse/jdt/core/tests/compiler/regression/AssignmentTest.java 1 Jun 2007 08:26:25 -0000 1.40 >+++ src/org/eclipse/jdt/core/tests/compiler/regression/AssignmentTest.java 23 Aug 2007 15:50:47 -0000 >@@ -33,7 +33,7 @@ > // All specified tests which does not belong to the class are skipped... > static { > // TESTS_NAMES = new String[] { "test000" }; >-// TESTS_NUMBERS = new int[] { 45 }; >+// TESTS_NUMBERS = new int[] { 2, 46, 47 }; > // TESTS_RANGE = new int[] { 11, -1 }; > } > public static Test suite() { >@@ -1102,6 +1102,40 @@ > "The assignment to variable length3 has no effect\n" + > "----------\n"); > } >+//https://bugs.eclipse.org/bugs/show_bug.cgi?id=200724 >+public void test046() { >+ this.runNegativeTest( >+ new String[] { >+ "X.java", >+ "public class X {\n" + >+ " public static String s;\n" + >+ " void foo(String s1) {\n" + >+ " X.s = s;" + >+ " }\n" + >+ "}\n", >+ }, >+ "----------\n" + >+ "1. ERROR in X.java (at line 4)\n" + >+ " X.s = s; }\n" + >+ " ^^^^^^^\n" + >+ "The assignment to variable s has no effect\n" + >+ "----------\n"); >+} >+//https://bugs.eclipse.org/bugs/show_bug.cgi?id=200724 >+public void test047() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "public class X {\n" + >+ " public static X MyX;\n" + >+ " public static String s;\n" + >+ " void foo(String s1) {\n" + >+ " X.MyX.s = s;" + >+ " }\n" + >+ "}\n", >+ }, >+ ""); >+} > public static Class testClass() { > return AssignmentTest.class; > }
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 200724
:
76783
|
76784
|
80549