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 48473 Details for
Bug 145397
[1.6][compiler] Invalid StackMap attribute
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Regression tests updated
patch_stack_map_32x_tests.txt (text/plain), 65.98 KB, created by
Olivier Thomann
on 2006-08-23 11:27:29 EDT
(
hide
)
Description:
Regression tests updated
Filename:
MIME Type:
Creator:
Olivier Thomann
Created:
2006-08-23 11:27:29 EDT
Size:
65.98 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.core.tests.compiler >Index: src/org/eclipse/jdt/core/tests/compiler/regression/ForeachStatementTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/ForeachStatementTest.java,v >retrieving revision 1.29.4.4 >diff -u -r1.29.4.4 ForeachStatementTest.java >--- src/org/eclipse/jdt/core/tests/compiler/regression/ForeachStatementTest.java 12 Jul 2006 16:04:57 -0000 1.29.4.4 >+++ src/org/eclipse/jdt/core/tests/compiler/regression/ForeachStatementTest.java 23 Aug 2006 15:29:54 -0000 >@@ -269,7 +269,7 @@ > " 66 iaload\n" + > " 67 istore_3 [e]\n" + > " 68 iload_3 [e]\n" + >- " 69 istore_1 [i]\n" + >+ " 69 istore_1\n" + > " 70 iinc 4 1\n" + > " 73 iload 4\n" + > " 75 iload 5\n" + >@@ -287,9 +287,8 @@ > " [pc: 88, line: 10]\n" + > " Local variable table:\n" + > " [pc: 0, pc: 89] local: args index: 0 type: java.lang.String[]\n" + >- " [pc: 70, pc: 73] local: i index: 1 type: int\n" + > " [pc: 48, pc: 89] local: tab index: 2 type: int[]\n" + >- " [pc: 68, pc: 80] local: e index: 3 type: int\n"; >+ " [pc: 68, pc: 70] local: e index: 3 type: int\n"; > > try { > File f = new File(OUTPUT_DIR + File.separator + "X.class"); >@@ -568,7 +567,7 @@ > /* > * Empty block action > */ >-public void test016() { >+public void test016() { > this.runConformTest( > new String[] { > "X.java", >@@ -717,7 +716,7 @@ > " Local variable table:\n" + > " [pc: 0, pc: 43] local: args index: 0 type: java.lang.String[]\n" + > " [pc: 8, pc: 43] local: tab index: 1 type: int[]\n" + >- " [pc: 26, pc: 42] local: e index: 2 type: int\n"; >+ " [pc: 26, pc: 36] local: e index: 2 type: int\n"; > > try { > File f = new File(OUTPUT_DIR + File.separator + "X.class"); >@@ -1029,7 +1028,7 @@ > " [pc: 48, pc: 119] local: tab index: 1 type: int[]\n" + > " [pc: 50, pc: 119] local: sum index: 2 type: int\n" + > " [pc: 52, pc: 119] local: i index: 3 type: int\n" + >- " [pc: 76, pc: 108] local: e index: 4 type: int\n"; >+ " [pc: 76, pc: 98] local: e index: 4 type: int\n"; > > try { > File f = new File(OUTPUT_DIR + File.separator + "X.class"); >@@ -1131,7 +1130,7 @@ > " [pc: 8, pc: 82] local: arrayList index: 1 type: java.util.ArrayList\n" + > " [pc: 10, pc: 35] local: i index: 2 type: int\n" + > " [pc: 37, pc: 82] local: sum index: 2 type: int\n" + >- " [pc: 57, pc: 74] local: e index: 3 type: java.lang.Integer\n" + >+ " [pc: 57, pc: 64] local: e index: 3 type: java.lang.Integer\n" + > " Local variable type table:\n" + > " [pc: 8, pc: 82] local: arrayList index: 1 type: java.util.ArrayList<java.lang.Integer>\n"; > >@@ -1269,8 +1268,8 @@ > " [pc: 0, pc: 93] local: args index: 0 type: java.lang.String[]\n" + > " [pc: 10, pc: 93] local: tab index: 1 type: java.lang.String[]\n" + > " [pc: 18, pc: 93] local: list index: 2 type: java.util.List\n" + >- " [pc: 38, pc: 56] local: arg index: 3 type: java.lang.String\n" + >- " [pc: 75, pc: 92] local: arg index: 3 type: java.lang.Object\n"; >+ " [pc: 38, pc: 46] local: arg index: 3 type: java.lang.String\n" + >+ " [pc: 75, pc: 82] local: arg index: 3 type: java.lang.Object\n"; > > try { > File f = new File(OUTPUT_DIR + File.separator + "X.class"); >@@ -1560,7 +1559,7 @@ > " [pc: 0, pc: 177] local: args index: 0 type: java.lang.String[]\n" + > " [pc: 8, pc: 177] local: slist index: 1 type: java.util.ArrayList\n" + > " [pc: 118, pc: 176] local: i index: 2 type: int\n" + >- " [pc: 148, pc: 165] local: s index: 3 type: java.lang.String\n" + >+ " [pc: 148, pc: 155] local: s index: 3 type: java.lang.String\n" + > " Local variable type table:\n" + > " [pc: 8, pc: 177] local: slist index: 1 type: java.util.ArrayList<java.util.ArrayList<java.lang.String>>\n"; > >@@ -1762,7 +1761,7 @@ > " Local variable table:\n" + > " [pc: 0, pc: 41] local: this index: 0 type: X\n" + > " [pc: 0, pc: 41] local: t index: 1 type: Bar\n" + >- " [pc: 18, pc: 34] local: s index: 2 type: java.lang.String\n" + >+ " [pc: 18, pc: 25] local: s index: 2 type: java.lang.String\n" + > " Local variable type table:\n" + > " [pc: 0, pc: 41] local: this index: 0 type: X<T>\n" + > " [pc: 0, pc: 41] local: t index: 1 type: T\n"; >@@ -1863,7 +1862,7 @@ > " Local variable table:\n" + > " [pc: 0, pc: 43] local: this index: 0 type: X\n" + > " [pc: 0, pc: 43] local: t index: 1 type: IFoo\n" + >- " [pc: 20, pc: 36] local: s index: 2 type: java.lang.String\n" + >+ " [pc: 20, pc: 27] local: s index: 2 type: java.lang.String\n" + > " Local variable type table:\n" + > " [pc: 0, pc: 43] local: this index: 0 type: X<T>\n" + > " [pc: 0, pc: 43] local: t index: 1 type: T\n"; >@@ -1940,7 +1939,7 @@ > " Local variable table:\n" + > " [pc: 0, pc: 37] local: this index: 0 type: X\n" + > " [pc: 0, pc: 37] local: t index: 1 type: java.lang.Runnable\n" + >- " [pc: 20, pc: 36] local: s index: 2 type: java.lang.String\n" + >+ " [pc: 20, pc: 27] local: s index: 2 type: java.lang.String\n" + > " Local variable type table:\n" + > " [pc: 0, pc: 37] local: t index: 1 type: T\n"; > >@@ -2015,7 +2014,7 @@ > " [pc: 34, line: 10]\n" + > " Local variable table:\n" + > " [pc: 0, pc: 35] local: t index: 0 type: java.util.ArrayList\n" + >- " [pc: 18, pc: 34] local: s index: 1 type: java.lang.String\n" + >+ " [pc: 18, pc: 25] local: s index: 1 type: java.lang.String\n" + > " Local variable type table:\n" + > " [pc: 0, pc: 35] local: t index: 0 type: T\n"; > >@@ -2086,7 +2085,7 @@ > " [pc: 37, line: 13]\n" + > " Local variable table:\n" + > " [pc: 0, pc: 38] local: this index: 0 type: X\n" + >- " [pc: 21, pc: 37] local: o index: 1 type: java.lang.Object\n"; >+ " [pc: 21, pc: 28] local: o index: 1 type: java.lang.Object\n"; > > try { > File f = new File(OUTPUT_DIR + File.separator + "X.class"); >@@ -2283,7 +2282,7 @@ > " 9 goto 19\n" + > " 12 aload_2\n" + > " 13 invokeinterface java.util.Iterator.next() : java.lang.Object [26] [nargs: 1]\n" + >- " 18 astore_1 [o]\n" + >+ " 18 astore_1\n" + > " 19 aload_2\n" + > " 20 invokeinterface java.util.Iterator.hasNext() : boolean [32] [nargs: 1]\n" + > " 25 ifne 12\n" + >@@ -2292,8 +2291,7 @@ > " [pc: 0, line: 8]\n" + > " [pc: 28, line: 10]\n" + > " Local variable table:\n" + >- " [pc: 0, pc: 29] local: args index: 0 type: java.lang.String[]\n" + >- " [pc: 19, pc: 28] local: o index: 1 type: java.lang.Object\n"; >+ " [pc: 0, pc: 29] local: args index: 0 type: java.lang.String[]\n"; > > try { > File f = new File(OUTPUT_DIR + File.separator + "X.class"); >@@ -2398,7 +2396,7 @@ > " 14 aload 4\n" + > " 16 iload_2\n" + > " 17 iaload\n" + >- " 18 istore_1 [i]\n" + >+ " 18 istore_1\n" + > " 19 iinc 2 1\n" + > " 22 iload_2\n" + > " 23 iload_3\n" + >@@ -2408,8 +2406,7 @@ > " [pc: 0, line: 3]\n" + > " [pc: 27, line: 5]\n" + > " Local variable table:\n" + >- " [pc: 0, pc: 28] local: args index: 0 type: java.lang.String[]\n" + >- " [pc: 19, pc: 27] local: i index: 1 type: int\n"; >+ " [pc: 0, pc: 28] local: args index: 0 type: java.lang.String[]\n"; > > try { > File f = new File(OUTPUT_DIR + File.separator + "X.class"); >@@ -2523,7 +2520,7 @@ > " 12 aload_3\n" + > " 13 iload_1\n" + > " 14 iaload\n" + >- " 15 istore_0 [i]\n" + >+ " 15 istore_0\n" + > " 16 iinc 1 1\n" + > " 19 iload_1\n" + > " 20 iload_2\n" + >@@ -2531,9 +2528,7 @@ > " 24 return\n" + > " Line numbers:\n" + > " [pc: 0, line: 6]\n" + >- " [pc: 24, line: 8]\n" + >- " Local variable table:\n" + >- " [pc: 16, pc: 24] local: i index: 0 type: int\n"; >+ " [pc: 24, line: 8]\n"; > > try { > File f = new File(OUTPUT_DIR + File.separator + "X.class"); >@@ -2610,7 +2605,7 @@ > " [pc: 35, line: 6]\n" + > " Local variable table:\n" + > " [pc: 0, pc: 36] local: args index: 0 type: java.lang.String[]\n" + >- " [pc: 19, pc: 35] local: i index: 1 type: int\n"; >+ " [pc: 19, pc: 27] local: i index: 1 type: int\n"; > > try { > File f = new File(OUTPUT_DIR + File.separator + "X.class"); >Index: src/org/eclipse/jdt/core/tests/compiler/regression/Compliance_1_5.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/Compliance_1_5.java,v >retrieving revision 1.54.4.1 >diff -u -r1.54.4.1 Compliance_1_5.java >--- src/org/eclipse/jdt/core/tests/compiler/regression/Compliance_1_5.java 2 Jul 2006 10:15:10 -0000 1.54.4.1 >+++ src/org/eclipse/jdt/core/tests/compiler/regression/Compliance_1_5.java 23 Aug 2006 15:29:54 -0000 >@@ -50,7 +50,7 @@ > // Names of tests to run: can be "testBugXXXX" or "BugXXXX") > // TESTS_NAMES = new String[] { "Bug58069" }; > // Numbers of tests to run: "test<number>" will be run for each number of this array >-// TESTS_NUMBERS = new int[] { 104 }; >+// TESTS_NUMBERS = new int[] { 88 }; > // Range numbers of tests to run: all tests between "test<first>" and "test<last>" will be run for { first, last } > // TESTS_RANGE = new int[] { 85, -1 }; > } >@@ -3083,6 +3083,67 @@ > ); > } > public void test088() { >+ String errorMessage = >+ "----------\n" + >+ "1. WARNING in p\\X.java (at line 4)\n" + >+ " public class X extends Date implements Runnable{\n" + >+ " ^\n" + >+ "The serializable class X does not declare a static final serialVersionUID field of type long\n" + >+ "----------\n" + >+ "2. ERROR in p\\X.java (at line 12)\n" + >+ " this.super();\n" + >+ " ^^^^\n" + >+ "Illegal enclosing instance specification for type Object\n" + >+ "----------\n" + >+ "3. WARNING in p\\X.java (at line 25)\n" + >+ " private void a() { System.out.println(\"A\");} \n" + >+ " ^^^\n" + >+ "The method a() from the type X is never used locally\n" + >+ "----------\n" + >+ "4. WARNING in p\\X.java (at line 31)\n" + >+ " Class c = b.getClass();\n" + >+ " ^^^^^\n" + >+ "Class is a raw type. References to generic type Class<T> should be parameterized\n" + >+ "----------\n" + >+ "5. WARNING in p\\X.java (at line 39)\n" + >+ " Method _getMethod = c.getMethod(\"d\",null);\n" + >+ " ^^^^^^^^^^^^^^^^^^^^^\n" + >+ "The argument of type null should explicitly be cast to Class[] for the invocation of the varargs method getMethod(String, Class...) from type Class. It could alternatively be cast to Class for a varargs invocation\n" + >+ "----------\n"; >+ if (System.getProperty("java.version").startsWith("1.6")) { >+ errorMessage = >+ "----------\n" + >+ "1. WARNING in p\\X.java (at line 4)\n" + >+ " public class X extends Date implements Runnable{\n" + >+ " ^\n" + >+ "The serializable class X does not declare a static final serialVersionUID field of type long\n" + >+ "----------\n" + >+ "2. ERROR in p\\X.java (at line 12)\n" + >+ " this.super();\n" + >+ " ^^^^\n" + >+ "Illegal enclosing instance specification for type Object\n" + >+ "----------\n" + >+ "3. WARNING in p\\X.java (at line 25)\n" + >+ " private void a() { System.out.println(\"A\");} \n" + >+ " ^^^\n" + >+ "The method a() from the type X is never used locally\n" + >+ "----------\n" + >+ "4. WARNING in p\\X.java (at line 31)\n" + >+ " Class c = b.getClass();\n" + >+ " ^^^^^\n" + >+ "Class is a raw type. References to generic type Class<T> should be parameterized\n" + >+ "----------\n" + >+ "5. WARNING in p\\X.java (at line 39)\n" + >+ " Method _getMethod = c.getMethod(\"d\",null);\n" + >+ " ^^^^^^^^^^^^^^^^^^^^^\n" + >+ "The argument of type null should explicitly be cast to Class[] for the invocation of the varargs method getMethod(String, Class...) from type Class. It could alternatively be cast to Class for a varargs invocation\n" + >+ "----------\n" + >+ "6. WARNING in p\\X.java (at line 39)\n" + >+ " Method _getMethod = c.getMethod(\"d\",null);\n" + >+ " ^^^^^^^^^^^^^^^^^^^^^\n" + >+ "Type safety: The method getMethod(String, Class...) belongs to the raw type Class. References to generic type Class<T> should be parameterized\n" + >+ "----------\n"; >+ } > this.runNegativeTest( > new String[] { > "p/X.java", >@@ -3134,32 +3195,7 @@ > " public void run() {System.out.println(\"RUN\");} \n" + > "}", > }, >- "----------\n" + >- "1. WARNING in p\\X.java (at line 4)\n" + >- " public class X extends Date implements Runnable{\n" + >- " ^\n" + >- "The serializable class X does not declare a static final serialVersionUID field of type long\n" + >- "----------\n" + >- "2. ERROR in p\\X.java (at line 12)\n" + >- " this.super();\n" + >- " ^^^^\n" + >- "Illegal enclosing instance specification for type Object\n" + >- "----------\n" + >- "3. WARNING in p\\X.java (at line 25)\n" + >- " private void a() { System.out.println(\"A\");} \n" + >- " ^^^\n" + >- "The method a() from the type X is never used locally\n" + >- "----------\n" + >- "4. WARNING in p\\X.java (at line 31)\n" + >- " Class c = b.getClass();\n" + >- " ^^^^^\n" + >- "Class is a raw type. References to generic type Class<T> should be parameterized\n" + >- "----------\n" + >- "5. WARNING in p\\X.java (at line 39)\n" + >- " Method _getMethod = c.getMethod(\"d\",null);\n" + >- " ^^^^^^^^^^^^^^^^^^^^^\n" + >- "The argument of type null should explicitly be cast to Class[] for the invocation of the varargs method getMethod(String, Class...) from type Class. It could alternatively be cast to Class for a varargs invocation\n" + >- "----------\n"); >+ errorMessage); > } > /* > * https://bugs.eclipse.org/bugs/show_bug.cgi?id=78089 >Index: src/org/eclipse/jdt/core/tests/compiler/regression/TryStatementTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/TryStatementTest.java,v >retrieving revision 1.25 >diff -u -r1.25 TryStatementTest.java >--- src/org/eclipse/jdt/core/tests/compiler/regression/TryStatementTest.java 11 Apr 2006 06:56:08 -0000 1.25 >+++ src/org/eclipse/jdt/core/tests/compiler/regression/TryStatementTest.java 23 Aug 2006 15:29:54 -0000 >@@ -2354,7 +2354,7 @@ > " 60 return\n" + > " 61 astore 4 [npe]\n" + > " 63 getstatic java.lang.System.out : java.io.PrintStream [15]\n" + >- " 66 aload_3\n" + >+ " 66 aload_3 [contexts]\n" + > " 67 invokevirtual java.io.PrintStream.print(java.lang.Object) : void [21]\n" + > " 70 goto 13\n" + > " 73 astore 5\n" + >@@ -2418,7 +2418,9 @@ > " [pc: 0, pc: 134] local: this index: 0 type: X\n" + > " [pc: 2, pc: 134] local: a index: 1 type: int\n" + > " [pc: 4, pc: 35] local: warnings index: 2 type: java.lang.Object\n" + >+ " [pc: 61, pc: 100] local: warnings index: 2 type: java.lang.Object\n" + > " [pc: 6, pc: 35] local: contexts index: 3 type: java.lang.Object\n" + >+ " [pc: 61, pc: 100] local: contexts index: 3 type: java.lang.Object\n" + > " [pc: 63, pc: 73] local: npe index: 4 type: java.lang.NullPointerException\n" + > " [pc: 101, pc: 104] local: e index: 2 type: java.lang.Exception\n" + > " [pc: 38, pc: 60] local: var index: 7 type: int\n" + >@@ -2706,7 +2708,7 @@ > " 44 ldc <String \"[npe]\"> [38]\n" + > " 46 invokevirtual java.io.PrintStream.print(java.lang.String) : void [23]\n" + > " 49 getstatic java.lang.System.out : java.io.PrintStream [15]\n" + >- " 52 aload_2\n" + >+ " 52 aload_2 [contexts]\n" + > " 53 invokevirtual java.io.PrintStream.print(java.lang.Object) : void [29]\n" + > " 56 goto 19\n" + > " 59 astore_1 [e]\n" + >@@ -2759,7 +2761,9 @@ > " Local variable table:\n" + > " [pc: 0, pc: 96] local: this index: 0 type: X\n" + > " [pc: 2, pc: 19] local: warnings index: 1 type: java.lang.Object\n" + >+ " [pc: 40, pc: 59] local: warnings index: 1 type: java.lang.Object\n" + > " [pc: 4, pc: 19] local: contexts index: 2 type: java.lang.Object\n" + >+ " [pc: 40, pc: 59] local: contexts index: 2 type: java.lang.Object\n" + > " [pc: 41, pc: 59] local: npe index: 3 type: java.lang.NullPointerException\n" + > " [pc: 60, pc: 71] local: e index: 1 type: java.lang.Exception\n" + > " [pc: 22, pc: 39] local: var index: 5 type: int\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/regression/StackMapAttributeTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/StackMapAttributeTest.java,v >retrieving revision 1.8.2.1 >diff -u -r1.8.2.1 StackMapAttributeTest.java >--- src/org/eclipse/jdt/core/tests/compiler/regression/StackMapAttributeTest.java 2 Jul 2006 10:15:10 -0000 1.8.2.1 >+++ src/org/eclipse/jdt/core/tests/compiler/regression/StackMapAttributeTest.java 23 Aug 2006 15:29:54 -0000 >@@ -33,7 +33,7 @@ > static { > // TESTS_PREFIX = "testBug95521"; > // TESTS_NAMES = new String[] { "testBug83127a" }; >-// TESTS_NUMBERS = new int[] { 7 }; >+// TESTS_NUMBERS = new int[] { 5, 17 }; > // TESTS_RANGE = new int[] { 23, -1 }; > } > public static Test suite() { >@@ -113,7 +113,7 @@ > " 34 invokevirtual java.lang.Exception.printStackTrace() : void [22]\n" + > " 37 return\n" + > " Exception Table:\n" + >- " [pc: 21, pc: 32] -> 32 when : java.lang.Exception\n" + >+ " [pc: 21, pc: 29] -> 32 when : java.lang.Exception\n" + > " Line numbers:\n" + > " [pc: 0, line: 4]\n" + > " [pc: 21, line: 6]\n" + >@@ -267,7 +267,7 @@ > " 40 astore 5 [e]\n" + > " 42 ldc2_w <Double 2.0> [20]\n" + > " 45 dstore_3 [i]\n" + >- " 46 goto 56\n" + >+ " 46 goto 61\n" + > " 49 astore 10\n" + > " 51 dconst_1\n" + > " 52 dstore_3 [i]\n" + >@@ -275,23 +275,26 @@ > " 55 athrow\n" + > " 56 dconst_1\n" + > " 57 dstore_3 [i]\n" + >- " 58 dload_3 [i]\n" + >- " 59 dconst_1\n" + >- " 60 dadd\n" + >- " 61 d2l\n" + >- " 62 lstore 5 [j]\n" + >- " 64 lload 5 [j]\n" + >- " 66 l2i\n" + >- " 67 istore 7 [k]\n" + >- " 69 iload 7 [k]\n" + >- " 71 i2l\n" + >- " 72 lload 5 [j]\n" + >- " 74 ladd\n" + >- " 75 l2i\n" + >- " 76 istore 7 [k]\n" + >- " 78 return\n" + >+ " 58 goto 63\n" + >+ " 61 dconst_1\n" + >+ " 62 dstore_3 [i]\n" + >+ " 63 dload_3 [i]\n" + >+ " 64 dconst_1\n" + >+ " 65 dadd\n" + >+ " 66 d2l\n" + >+ " 67 lstore 5 [j]\n" + >+ " 69 lload 5 [j]\n" + >+ " 71 l2i\n" + >+ " 72 istore 7 [k]\n" + >+ " 74 iload 7 [k]\n" + >+ " 76 i2l\n" + >+ " 77 lload 5 [j]\n" + >+ " 79 ladd\n" + >+ " 80 l2i\n" + >+ " 81 istore 7 [k]\n" + >+ " 83 return\n" + > " Exception Table:\n" + >- " [pc: 0, pc: 40] -> 40 when : java.lang.NullPointerException\n" + >+ " [pc: 0, pc: 37] -> 40 when : java.lang.NullPointerException\n" + > " [pc: 0, pc: 49] -> 49 when : any\n" + > " Line numbers:\n" + > " [pc: 0, line: 5]\n" + >@@ -309,28 +312,31 @@ > " [pc: 51, line: 19]\n" + > " [pc: 53, line: 20]\n" + > " [pc: 56, line: 19]\n" + >- " [pc: 58, line: 21]\n" + >- " [pc: 64, line: 22]\n" + >- " [pc: 69, line: 23]\n" + >- " [pc: 78, line: 24]\n" + >+ " [pc: 61, line: 18]\n" + >+ " [pc: 63, line: 21]\n" + >+ " [pc: 69, line: 22]\n" + >+ " [pc: 74, line: 23]\n" + >+ " [pc: 83, line: 24]\n" + > " Local variable table:\n" + >- " [pc: 0, pc: 79] local: d index: 0 type: double\n" + >- " [pc: 0, pc: 79] local: b index: 2 type: boolean\n" + >+ " [pc: 0, pc: 84] local: d index: 0 type: double\n" + >+ " [pc: 0, pc: 84] local: b index: 2 type: boolean\n" + > " [pc: 2, pc: 40] local: i index: 3 type: double\n" + > " [pc: 46, pc: 49] local: i index: 3 type: double\n" + >- " [pc: 53, pc: 56] local: i index: 3 type: double\n" + >- " [pc: 58, pc: 79] local: i index: 3 type: double\n" + >+ " [pc: 53, pc: 61] local: i index: 3 type: double\n" + >+ " [pc: 63, pc: 84] local: i index: 3 type: double\n" + > " [pc: 12, pc: 40] local: j index: 5 type: int\n" + > " [pc: 19, pc: 32] local: d1 index: 6 type: double\n" + > " [pc: 42, pc: 46] local: e index: 5 type: java.lang.NullPointerException\n" + >- " [pc: 64, pc: 79] local: j index: 5 type: long\n" + >- " [pc: 69, pc: 79] local: k index: 7 type: int\n" + >- " Stack map table: number of frames 5\n" + >+ " [pc: 69, pc: 84] local: j index: 5 type: long\n" + >+ " [pc: 74, pc: 84] local: k index: 7 type: int\n" + >+ " Stack map table: number of frames 7\n" + > " [pc: 26, append: {double, int, double}]\n" + > " [pc: 32, chop 1 local(s)]\n" + > " [pc: 40, full, stack: {java.lang.NullPointerException}, locals: {double, int}]\n" + > " [pc: 49, same_locals_1_stack_item, stack: {java.lang.Throwable}]\n" + >- " [pc: 56, append: {double}]\n"; >+ " [pc: 56, append: {double}]\n" + >+ " [pc: 61, chop 1 local(s)]\n" + >+ " [pc: 63, append: {double}]\n"; > > int index = actualOutput.indexOf(expectedOutput); > if (index == -1 || expectedOutput.length() == 0) { >@@ -405,7 +411,7 @@ > " 24 astore_2 [e]\n" + > " 25 aload_2 [e]\n" + > " 26 invokevirtual java.lang.NullPointerException.printStackTrace() : void [34]\n" + >- " 29 goto 43\n" + >+ " 29 goto 54\n" + > " 32 astore_3\n" + > " 33 getstatic java.lang.System.out : java.io.PrintStream [16]\n" + > " 36 ldc <String \"FINALLY\"> [22]\n" + >@@ -415,9 +421,13 @@ > " 43 getstatic java.lang.System.out : java.io.PrintStream [16]\n" + > " 46 ldc <String \"FINALLY\"> [22]\n" + > " 48 invokevirtual java.io.PrintStream.println(java.lang.String) : void [24]\n" + >- " 51 return\n" + >+ " 51 goto 62\n" + >+ " 54 getstatic java.lang.System.out : java.io.PrintStream [16]\n" + >+ " 57 ldc <String \"FINALLY\"> [22]\n" + >+ " 59 invokevirtual java.io.PrintStream.println(java.lang.String) : void [24]\n" + >+ " 62 return\n" + > " Exception Table:\n" + >- " [pc: 2, pc: 24] -> 24 when : java.lang.NullPointerException\n" + >+ " [pc: 2, pc: 21] -> 24 when : java.lang.NullPointerException\n" + > " [pc: 2, pc: 32] -> 32 when : any\n" + > " Line numbers:\n" + > " [pc: 0, line: 3]\n" + >@@ -431,16 +441,19 @@ > " [pc: 33, line: 12]\n" + > " [pc: 41, line: 13]\n" + > " [pc: 43, line: 12]\n" + >- " [pc: 51, line: 14]\n" + >+ " [pc: 54, line: 11]\n" + >+ " [pc: 62, line: 14]\n" + > " Local variable table:\n" + >- " [pc: 0, pc: 52] local: b index: 0 type: boolean\n" + >- " [pc: 2, pc: 52] local: i index: 1 type: int\n" + >+ " [pc: 0, pc: 63] local: b index: 0 type: boolean\n" + >+ " [pc: 2, pc: 63] local: i index: 1 type: int\n" + > " [pc: 17, pc: 24] local: j index: 2 type: int\n" + > " [pc: 25, pc: 29] local: e index: 2 type: java.lang.NullPointerException\n" + >- " Stack map table: number of frames 3\n" + >+ " Stack map table: number of frames 5\n" + > " [pc: 24, full, stack: {java.lang.NullPointerException}, locals: {int, int}]\n" + > " [pc: 32, same_locals_1_stack_item, stack: {java.lang.Throwable}]\n" + >- " [pc: 43, same]\n"; >+ " [pc: 43, same]\n" + >+ " [pc: 54, same]\n" + >+ " [pc: 62, same]\n"; > > int index = actualOutput.indexOf(expectedOutput); > if (index == -1 || expectedOutput.length() == 0) { >@@ -656,8 +669,9 @@ > " [pc: 35, pc: 38] local: l index: 4 type: int\n" + > " [pc: 41, pc: 82] local: l index: 4 type: int\n" + > " [pc: 28, pc: 82] local: b index: 5 type: boolean\n" + >- " Stack map table: number of frames 5\n" + >+ " Stack map table: number of frames 6\n" + > " [pc: 19, append: {int}]\n" + >+ " [pc: 21, full, stack: {}, locals: {java.lang.String[], int, _, int}]\n" + > " [pc: 38, full, stack: {}, locals: {java.lang.String[], int, _, int, _, int}]\n" + > " [pc: 41, full, stack: {}, locals: {java.lang.String[], int, _, int, int, int}]\n" + > " [pc: 65, full, stack: {}, locals: {java.lang.String[], int, int, int, int, int}]\n" + >@@ -887,7 +901,7 @@ > " [pc: 5, pc: 24] local: bar index: 2 type: java.lang.String\n" + > " Stack map table: number of frames 2\n" + > " [pc: 19, full, stack: {java.io.PrintStream}, locals: {java.lang.String[], int, java.lang.String}]\n" + >- " [pc: 20, full, stack: {java.io.PrintStream, java.lang.Comparable}, locals: {java.lang.String[], int, java.lang.Comparable}]\n" + >+ " [pc: 20, full, stack: {java.io.PrintStream, java.lang.Comparable}, locals: {java.lang.String[], int, java.lang.String}]\n" + > " \n" + > " // Method descriptor #48 (Ljava/lang/Comparable;)V\n" + > " // Signature: <T::Ljava/lang/Comparable<*>;>(TT;)V\n" + >@@ -1015,4 +1029,988 @@ > assertEquals("Wrong contents", expectedOutput, actualOutput); > } > } >+ >+ public void test010() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "public class X {\n" + >+ " public static void main(String[] args) {\n" + >+ " int[] tab = new int[0];\n" + >+ " Object o = tab;\n" + >+ " Object o1 = null;\n" + >+ " if (tab.length == 0) {\n" + >+ " System.out.println(tab.getClass());\n" + >+ " }\n" + >+ " o1 = tab.clone();\n" + >+ " }\n" + >+ "}", >+ }, >+ "class [I"); >+ >+ ClassFileBytesDisassembler disassembler = ToolFactory.createDefaultClassFileBytesDisassembler(); >+ String actualOutput = null; >+ try { >+ byte[] classFileBytes = org.eclipse.jdt.internal.compiler.util.Util.getFileByteContent(new File(OUTPUT_DIR + File.separator +"X.class")); >+ actualOutput = >+ disassembler.disassemble( >+ classFileBytes, >+ "\n", >+ ClassFileBytesDisassembler.DETAILED); >+ } catch (org.eclipse.jdt.core.util.ClassFormatException e) { >+ assertTrue("ClassFormatException", false); >+ } catch (IOException e) { >+ assertTrue("IOException", false); >+ } >+ >+ String expectedOutput = >+ " // Method descriptor #15 ([Ljava/lang/String;)V\n" + >+ " // Stack: 2, Locals: 4\n" + >+ " public static void main(java.lang.String[] args);\n" + >+ " 0 iconst_0\n" + >+ " 1 newarray int [10]\n" + >+ " 3 astore_1 [tab]\n" + >+ " 4 aload_1 [tab]\n" + >+ " 5 astore_2 [o]\n" + >+ " 6 aconst_null\n" + >+ " 7 astore_3 [o1]\n" + >+ " 8 aload_1 [tab]\n" + >+ " 9 arraylength\n" + >+ " 10 ifne 23\n" + >+ " 13 getstatic java.lang.System.out : java.io.PrintStream [16]\n" + >+ " 16 aload_1 [tab]\n" + >+ " 17 invokevirtual java.lang.Object.getClass() : java.lang.Class [22]\n" + >+ " 20 invokevirtual java.io.PrintStream.println(java.lang.Object) : void [26]\n" + >+ " 23 aload_1 [tab]\n" + >+ " 24 invokevirtual int[].clone() : java.lang.Object [32]\n" + >+ " 27 astore_3 [o1]\n" + >+ " 28 return\n" + >+ " Line numbers:\n" + >+ " [pc: 0, line: 3]\n" + >+ " [pc: 4, line: 4]\n" + >+ " [pc: 6, line: 5]\n" + >+ " [pc: 8, line: 6]\n" + >+ " [pc: 13, line: 7]\n" + >+ " [pc: 23, line: 9]\n" + >+ " [pc: 28, line: 10]\n" + >+ " Local variable table:\n" + >+ " [pc: 0, pc: 29] local: args index: 0 type: java.lang.String[]\n" + >+ " [pc: 4, pc: 29] local: tab index: 1 type: int[]\n" + >+ " [pc: 6, pc: 29] local: o index: 2 type: java.lang.Object\n" + >+ " [pc: 8, pc: 29] local: o1 index: 3 type: java.lang.Object\n" + >+ " Stack map table: number of frames 1\n" + >+ " [pc: 23, append: {int[], java.lang.Object, java.lang.Object}]\n"; >+ >+ int index = actualOutput.indexOf(expectedOutput); >+ if (index == -1 || expectedOutput.length() == 0) { >+ System.out.println(Util.displayString(actualOutput, 2)); >+ } >+ if (index == -1) { >+ assertEquals("Wrong contents", expectedOutput, actualOutput); >+ } >+ } >+ >+ public void test011() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "public class X {\n" + >+ " Object o;\n" + >+ "\n" + >+ " public static void main(String[] args) {\n" + >+ " X x;\n" + >+ " for (int i = 0; i < 10; i++) {\n" + >+ " if (i < 90) {\n" + >+ " x = new X();\n" + >+ " if (i > 4) {\n" + >+ " x.o = new Object();\n" + >+ " } else {\n" + >+ " x.o = \"0\";\n" + >+ " }\n" + >+ " switch (i) {\n" + >+ " case 0:\n" + >+ " if (x.o instanceof String) {\n" + >+ " System.out.print(\"1\");\n" + >+ " }\n" + >+ " break;\n" + >+ " default: {\n" + >+ " Object diff = x.o;\n" + >+ " if (diff != null) {\n" + >+ " System.out.print(\"2\");\n" + >+ " }\n" + >+ " }\n" + >+ " }\n" + >+ " }\n" + >+ " }\n" + >+ " }\n" + >+ "}", >+ }, >+ "1222222222"); >+ >+ ClassFileBytesDisassembler disassembler = ToolFactory.createDefaultClassFileBytesDisassembler(); >+ String actualOutput = null; >+ try { >+ byte[] classFileBytes = org.eclipse.jdt.internal.compiler.util.Util.getFileByteContent(new File(OUTPUT_DIR + File.separator +"X.class")); >+ actualOutput = >+ disassembler.disassemble( >+ classFileBytes, >+ "\n", >+ ClassFileBytesDisassembler.DETAILED); >+ } catch (org.eclipse.jdt.core.util.ClassFormatException e) { >+ assertTrue("ClassFormatException", false); >+ } catch (IOException e) { >+ assertTrue("IOException", false); >+ } >+ >+ String expectedOutput = >+ " // Method descriptor #17 ([Ljava/lang/String;)V\n" + >+ " // Stack: 3, Locals: 4\n" + >+ " public static void main(java.lang.String[] args);\n" + >+ " 0 iconst_0\n" + >+ " 1 istore_2 [i]\n" + >+ " 2 goto 105\n" + >+ " 5 iload_2 [i]\n" + >+ " 6 bipush 90\n" + >+ " 8 if_icmpge 102\n" + >+ " 11 new X [1]\n" + >+ " 14 dup\n" + >+ " 15 invokespecial X() [18]\n" + >+ " 18 astore_1 [x]\n" + >+ " 19 iload_2 [i]\n" + >+ " 20 iconst_4\n" + >+ " 21 if_icmple 38\n" + >+ " 24 aload_1 [x]\n" + >+ " 25 new java.lang.Object [3]\n" + >+ " 28 dup\n" + >+ " 29 invokespecial java.lang.Object() [10]\n" + >+ " 32 putfield X.o : java.lang.Object [19]\n" + >+ " 35 goto 44\n" + >+ " 38 aload_1 [x]\n" + >+ " 39 ldc <String \"0\"> [21]\n" + >+ " 41 putfield X.o : java.lang.Object [19]\n" + >+ " 44 iload_2 [i]\n" + >+ " 45 tableswitch default: 85\n" + >+ " case 0: 64\n" + >+ " 64 aload_1 [x]\n" + >+ " 65 getfield X.o : java.lang.Object [19]\n" + >+ " 68 instanceof java.lang.String [23]\n" + >+ " 71 ifeq 102\n" + >+ " 74 getstatic java.lang.System.out : java.io.PrintStream [25]\n" + >+ " 77 ldc <String \"1\"> [31]\n" + >+ " 79 invokevirtual java.io.PrintStream.print(java.lang.String) : void [33]\n" + >+ " 82 goto 102\n" + >+ " 85 aload_1 [x]\n" + >+ " 86 getfield X.o : java.lang.Object [19]\n" + >+ " 89 astore_3 [diff]\n" + >+ " 90 aload_3 [diff]\n" + >+ " 91 ifnull 102\n" + >+ " 94 getstatic java.lang.System.out : java.io.PrintStream [25]\n" + >+ " 97 ldc <String \"2\"> [39]\n" + >+ " 99 invokevirtual java.io.PrintStream.print(java.lang.String) : void [33]\n" + >+ " 102 iinc 2 1 [i]\n" + >+ " 105 iload_2 [i]\n" + >+ " 106 bipush 10\n" + >+ " 108 if_icmplt 5\n" + >+ " 111 return\n" + >+ " Line numbers:\n" + >+ " [pc: 0, line: 6]\n" + >+ " [pc: 5, line: 7]\n" + >+ " [pc: 11, line: 8]\n" + >+ " [pc: 19, line: 9]\n" + >+ " [pc: 24, line: 10]\n" + >+ " [pc: 38, line: 12]\n" + >+ " [pc: 44, line: 14]\n" + >+ " [pc: 64, line: 16]\n" + >+ " [pc: 74, line: 17]\n" + >+ " [pc: 82, line: 19]\n" + >+ " [pc: 85, line: 21]\n" + >+ " [pc: 90, line: 22]\n" + >+ " [pc: 94, line: 23]\n" + >+ " [pc: 102, line: 6]\n" + >+ " [pc: 111, line: 29]\n" + >+ " Local variable table:\n" + >+ " [pc: 0, pc: 112] local: args index: 0 type: java.lang.String[]\n" + >+ " [pc: 19, pc: 102] local: x index: 1 type: X\n" + >+ " [pc: 2, pc: 111] local: i index: 2 type: int\n" + >+ " [pc: 90, pc: 102] local: diff index: 3 type: java.lang.Object\n" + >+ " Stack map table: number of frames 8\n" + >+ " [pc: 5, full, stack: {}, locals: {java.lang.String[], _, int}]\n" + >+ " [pc: 38, full, stack: {}, locals: {java.lang.String[], X, int}]\n" + >+ " [pc: 44, same]\n" + >+ " [pc: 64, same]\n" + >+ " [pc: 82, same]\n" + >+ " [pc: 85, same]\n" + >+ " [pc: 102, full, stack: {}, locals: {java.lang.String[], _, int}]\n" + >+ " [pc: 105, same]\n"; >+ >+ int index = actualOutput.indexOf(expectedOutput); >+ if (index == -1 || expectedOutput.length() == 0) { >+ System.out.println(Util.displayString(actualOutput, 2)); >+ } >+ if (index == -1) { >+ assertEquals("Wrong contents", expectedOutput, actualOutput); >+ } >+ } >+ >+ public void test012() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "public class X {\n" + >+ " public static void main(String[] args) {\n" + >+ " X x;\n" + >+ " Object o;\n" + >+ " for (int i = 0; i < 10; i++) {\n" + >+ " if (i < 90) {\n" + >+ " x = new X();\n" + >+ " if (i > 4) {\n" + >+ " o = new Object();\n" + >+ " } else {\n" + >+ " o = null;\n" + >+ " }\n" + >+ " switch (i) {\n" + >+ " case 0:\n" + >+ " if (o instanceof String) {\n" + >+ " System.out.print(\"1\");\n" + >+ " return;\n" + >+ " } else {\n" + >+ " break;\n" + >+ " }\n" + >+ " default: {\n" + >+ " Object diff = o;\n" + >+ " if (diff != null) {\n" + >+ " System.out.print(\"2\");\n" + >+ " }\n" + >+ " break;\n" + >+ " }\n" + >+ " }\n" + >+ " System.out.print(\"3\");\n" + >+ " }\n" + >+ " }\n" + >+ " }\n" + >+ "}", >+ }, >+ "333332323232323"); >+ >+ ClassFileBytesDisassembler disassembler = ToolFactory.createDefaultClassFileBytesDisassembler(); >+ String actualOutput = null; >+ try { >+ byte[] classFileBytes = org.eclipse.jdt.internal.compiler.util.Util.getFileByteContent(new File(OUTPUT_DIR + File.separator +"X.class")); >+ actualOutput = >+ disassembler.disassemble( >+ classFileBytes, >+ "\n", >+ ClassFileBytesDisassembler.DETAILED); >+ } catch (org.eclipse.jdt.core.util.ClassFormatException e) { >+ assertTrue("ClassFormatException", false); >+ } catch (IOException e) { >+ assertTrue("IOException", false); >+ } >+ >+ String expectedOutput = >+ " // Method descriptor #15 ([Ljava/lang/String;)V\n" + >+ " // Stack: 2, Locals: 5\n" + >+ " public static void main(java.lang.String[] args);\n" + >+ " 0 iconst_0\n" + >+ " 1 istore_3 [i]\n" + >+ " 2 goto 102\n" + >+ " 5 iload_3 [i]\n" + >+ " 6 bipush 90\n" + >+ " 8 if_icmpge 99\n" + >+ " 11 new X [1]\n" + >+ " 14 dup\n" + >+ " 15 invokespecial X() [16]\n" + >+ " 18 astore_1 [x]\n" + >+ " 19 iload_3 [i]\n" + >+ " 20 iconst_4\n" + >+ " 21 if_icmple 35\n" + >+ " 24 new java.lang.Object [3]\n" + >+ " 27 dup\n" + >+ " 28 invokespecial java.lang.Object() [8]\n" + >+ " 31 astore_2 [o]\n" + >+ " 32 goto 37\n" + >+ " 35 aconst_null\n" + >+ " 36 astore_2 [o]\n" + >+ " 37 iload_3 [i]\n" + >+ " 38 tableswitch default: 75\n" + >+ " case 0: 56\n" + >+ " 56 aload_2 [o]\n" + >+ " 57 instanceof java.lang.String [17]\n" + >+ " 60 ifeq 91\n" + >+ " 63 getstatic java.lang.System.out : java.io.PrintStream [19]\n" + >+ " 66 ldc <String \"1\"> [25]\n" + >+ " 68 invokevirtual java.io.PrintStream.print(java.lang.String) : void [27]\n" + >+ " 71 return\n" + >+ " 72 goto 91\n" + >+ " 75 aload_2 [o]\n" + >+ " 76 astore 4 [diff]\n" + >+ " 78 aload 4 [diff]\n" + >+ " 80 ifnull 91\n" + >+ " 83 getstatic java.lang.System.out : java.io.PrintStream [19]\n" + >+ " 86 ldc <String \"2\"> [33]\n" + >+ " 88 invokevirtual java.io.PrintStream.print(java.lang.String) : void [27]\n" + >+ " 91 getstatic java.lang.System.out : java.io.PrintStream [19]\n" + >+ " 94 ldc <String \"3\"> [35]\n" + >+ " 96 invokevirtual java.io.PrintStream.print(java.lang.String) : void [27]\n" + >+ " 99 iinc 3 1 [i]\n" + >+ " 102 iload_3 [i]\n" + >+ " 103 bipush 10\n" + >+ " 105 if_icmplt 5\n" + >+ " 108 return\n" + >+ " Line numbers:\n" + >+ " [pc: 0, line: 5]\n" + >+ " [pc: 5, line: 6]\n" + >+ " [pc: 11, line: 7]\n" + >+ " [pc: 19, line: 8]\n" + >+ " [pc: 24, line: 9]\n" + >+ " [pc: 35, line: 11]\n" + >+ " [pc: 37, line: 13]\n" + >+ " [pc: 56, line: 15]\n" + >+ " [pc: 63, line: 16]\n" + >+ " [pc: 71, line: 17]\n" + >+ " [pc: 72, line: 19]\n" + >+ " [pc: 75, line: 22]\n" + >+ " [pc: 78, line: 23]\n" + >+ " [pc: 83, line: 24]\n" + >+ " [pc: 91, line: 29]\n" + >+ " [pc: 99, line: 5]\n" + >+ " [pc: 108, line: 32]\n" + >+ " Local variable table:\n" + >+ " [pc: 0, pc: 109] local: args index: 0 type: java.lang.String[]\n" + >+ " [pc: 19, pc: 99] local: x index: 1 type: X\n" + >+ " [pc: 32, pc: 35] local: o index: 2 type: java.lang.Object\n" + >+ " [pc: 37, pc: 99] local: o index: 2 type: java.lang.Object\n" + >+ " [pc: 2, pc: 108] local: i index: 3 type: int\n" + >+ " [pc: 78, pc: 91] local: diff index: 4 type: java.lang.Object\n" + >+ " Stack map table: number of frames 9\n" + >+ " [pc: 5, full, stack: {}, locals: {java.lang.String[], _, _, int}]\n" + >+ " [pc: 35, full, stack: {}, locals: {java.lang.String[], X, _, int}]\n" + >+ " [pc: 37, full, stack: {}, locals: {java.lang.String[], X, java.lang.Object, int}]\n" + >+ " [pc: 56, same]\n" + >+ " [pc: 72, same]\n" + >+ " [pc: 75, same]\n" + >+ " [pc: 91, same]\n" + >+ " [pc: 99, full, stack: {}, locals: {java.lang.String[], _, _, int}]\n" + >+ " [pc: 102, same]\n"; >+ >+ int index = actualOutput.indexOf(expectedOutput); >+ if (index == -1 || expectedOutput.length() == 0) { >+ System.out.println(Util.displayString(actualOutput, 2)); >+ } >+ if (index == -1) { >+ assertEquals("Wrong contents", expectedOutput, actualOutput); >+ } >+ } >+ >+ public void test013() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "public class X {\n" + >+ "\n" + >+ " void foo() {\n" + >+ " synchronized (this) {\n" + >+ " int n=0;\n" + >+ " try {\n" + >+ " Thread.sleep(n); \n" + >+ " } catch (Exception e ) {\n" + >+ " }\n" + >+ " }\n" + >+ " }\n" + >+ " \n" + >+ " public static void main(String[] args) {}\n" + >+ "}", >+ }, >+ ""); >+ >+ ClassFileBytesDisassembler disassembler = ToolFactory.createDefaultClassFileBytesDisassembler(); >+ String actualOutput = null; >+ try { >+ byte[] classFileBytes = org.eclipse.jdt.internal.compiler.util.Util.getFileByteContent(new File(OUTPUT_DIR + File.separator +"X.class")); >+ actualOutput = >+ disassembler.disassemble( >+ classFileBytes, >+ "\n", >+ ClassFileBytesDisassembler.DETAILED); >+ } catch (org.eclipse.jdt.core.util.ClassFormatException e) { >+ assertTrue("ClassFormatException", false); >+ } catch (IOException e) { >+ assertTrue("IOException", false); >+ } >+ >+ String expectedOutput = >+ " // Method descriptor #6 ()V\n" + >+ " // Stack: 2, Locals: 4\n" + >+ " void foo();\n" + >+ " 0 aload_0 [this]\n" + >+ " 1 dup\n" + >+ " 2 astore_1\n" + >+ " 3 monitorenter\n" + >+ " 4 iconst_0\n" + >+ " 5 istore_2 [n]\n" + >+ " 6 iload_2 [n]\n" + >+ " 7 i2l\n" + >+ " 8 invokestatic java.lang.Thread.sleep(long) : void [15]\n" + >+ " 11 goto 15\n" + >+ " 14 astore_3\n" + >+ " 15 aload_1\n" + >+ " 16 monitorexit\n" + >+ " 17 goto 23\n" + >+ " 20 aload_1\n" + >+ " 21 monitorexit\n" + >+ " 22 athrow\n" + >+ " 23 return\n" + >+ " Exception Table:\n" + >+ " [pc: 6, pc: 11] -> 14 when : java.lang.Exception\n" + >+ " [pc: 4, pc: 17] -> 20 when : any\n" + >+ " [pc: 20, pc: 22] -> 20 when : any\n" + >+ " Line numbers:\n" + >+ " [pc: 0, line: 4]\n" + >+ " [pc: 4, line: 5]\n" + >+ " [pc: 6, line: 7]\n" + >+ " [pc: 14, line: 8]\n" + >+ " [pc: 15, line: 4]\n" + >+ " [pc: 23, line: 11]\n" + >+ " Local variable table:\n" + >+ " [pc: 0, pc: 24] local: this index: 0 type: X\n" + >+ " [pc: 6, pc: 15] local: n index: 2 type: int\n" + >+ " Stack map table: number of frames 4\n" + >+ " [pc: 14, full, stack: {java.lang.Exception}, locals: {X, X, int}]\n" + >+ " [pc: 15, chop 1 local(s)]\n" + >+ " [pc: 20, same_locals_1_stack_item, stack: {java.lang.Throwable}]\n" + >+ " [pc: 23, chop 1 local(s)]\n"; >+ >+ int index = actualOutput.indexOf(expectedOutput); >+ if (index == -1 || expectedOutput.length() == 0) { >+ System.out.println(Util.displayString(actualOutput, 2)); >+ } >+ if (index == -1) { >+ assertEquals("Wrong contents", expectedOutput, actualOutput); >+ } >+ } >+ >+ public void test014() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "public class X {\n" + >+ " X() {\n" + >+ " final int i;\n" + >+ " synchronized (this) {\n" + >+ " i = 8;\n" + >+ " }\n" + >+ " } \n" + >+ " public static void main(String[] args) {}\n" + >+ "}", >+ }, >+ ""); >+ >+ ClassFileBytesDisassembler disassembler = ToolFactory.createDefaultClassFileBytesDisassembler(); >+ String actualOutput = null; >+ try { >+ byte[] classFileBytes = org.eclipse.jdt.internal.compiler.util.Util.getFileByteContent(new File(OUTPUT_DIR + File.separator +"X.class")); >+ actualOutput = >+ disassembler.disassemble( >+ classFileBytes, >+ "\n", >+ ClassFileBytesDisassembler.DETAILED); >+ } catch (org.eclipse.jdt.core.util.ClassFormatException e) { >+ assertTrue("ClassFormatException", false); >+ } catch (IOException e) { >+ assertTrue("IOException", false); >+ } >+ >+ String expectedOutput = >+ " // Method descriptor #6 ()V\n" + >+ " // Stack: 2, Locals: 3\n" + >+ " X();\n" + >+ " 0 aload_0 [this]\n" + >+ " 1 invokespecial java.lang.Object() [8]\n" + >+ " 4 aload_0 [this]\n" + >+ " 5 dup\n" + >+ " 6 astore_2\n" + >+ " 7 monitorenter\n" + >+ " 8 bipush 8\n" + >+ " 10 istore_1 [i]\n" + >+ " 11 aload_2\n" + >+ " 12 monitorexit\n" + >+ " 13 goto 19\n" + >+ " 16 aload_2\n" + >+ " 17 monitorexit\n" + >+ " 18 athrow\n" + >+ " 19 return\n" + >+ " Exception Table:\n" + >+ " [pc: 8, pc: 13] -> 16 when : any\n" + >+ " [pc: 16, pc: 18] -> 16 when : any\n" + >+ " Line numbers:\n" + >+ " [pc: 0, line: 2]\n" + >+ " [pc: 4, line: 4]\n" + >+ " [pc: 8, line: 5]\n" + >+ " [pc: 11, line: 4]\n" + >+ " [pc: 19, line: 7]\n" + >+ " Local variable table:\n" + >+ " [pc: 0, pc: 20] local: this index: 0 type: X\n" + >+ " [pc: 11, pc: 16] local: i index: 1 type: int\n" + >+ " [pc: 19, pc: 20] local: i index: 1 type: int\n" + >+ " Stack map table: number of frames 2\n" + >+ " [pc: 16, full, stack: {java.lang.Throwable}, locals: {X, _, X}]\n" + >+ " [pc: 19, full, stack: {}, locals: {X, int}]\n"; >+ >+ int index = actualOutput.indexOf(expectedOutput); >+ if (index == -1 || expectedOutput.length() == 0) { >+ System.out.println(Util.displayString(actualOutput, 2)); >+ } >+ if (index == -1) { >+ assertEquals("Wrong contents", expectedOutput, actualOutput); >+ } >+ } >+ >+ public void test015() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "public enum X {\n" + >+ " a1(1), a2(5), a3(11);\n" + >+ " int value;\n" + >+ " X(int a) {\n" + >+ " value = a;\n" + >+ " }\n" + >+ " int value () {\n" + >+ " return value;\n" + >+ " }\n" + >+ " public static void main(String argv[]) {\n" + >+ " }\n" + >+ " public static int foo() {\n" + >+ " int val;\n" + >+ " int res = 0;\n" + >+ " int n = 0;\n" + >+ " X[] vals = X.values();\n" + >+ " for (int i = 0, max = vals.length; i < max; i++) {\n" + >+ " X e = vals[i];\n" + >+ " if ( n == 1) {\n" + >+ " continue;\n" + >+ " }\n" + >+ " val = e.value();\n" + >+ " System.out.println(val);\n" + >+ " }\n" + >+ " return res;\n" + >+ " }\n" + >+ "}", >+ }, >+ ""); >+ >+ ClassFileBytesDisassembler disassembler = ToolFactory.createDefaultClassFileBytesDisassembler(); >+ String actualOutput = null; >+ try { >+ byte[] classFileBytes = org.eclipse.jdt.internal.compiler.util.Util.getFileByteContent(new File(OUTPUT_DIR + File.separator +"X.class")); >+ actualOutput = >+ disassembler.disassemble( >+ classFileBytes, >+ "\n", >+ ClassFileBytesDisassembler.DETAILED); >+ } catch (org.eclipse.jdt.core.util.ClassFormatException e) { >+ assertTrue("ClassFormatException", false); >+ } catch (IOException e) { >+ assertTrue("IOException", false); >+ } >+ >+ String expectedOutput = >+ " // Method descriptor #40 ()I\n" + >+ " // Stack: 2, Locals: 7\n" + >+ " public static int foo();\n" + >+ " 0 iconst_0\n" + >+ " 1 istore_1 [res]\n" + >+ " 2 iconst_0\n" + >+ " 3 istore_2 [n]\n" + >+ " 4 invokestatic X.values() : X[] [46]\n" + >+ " 7 astore_3 [vals]\n" + >+ " 8 iconst_0\n" + >+ " 9 istore 4 [i]\n" + >+ " 11 aload_3 [vals]\n" + >+ " 12 arraylength\n" + >+ " 13 istore 5 [max]\n" + >+ " 15 goto 48\n" + >+ " 18 aload_3 [vals]\n" + >+ " 19 iload 4 [i]\n" + >+ " 21 aaload\n" + >+ " 22 astore 6 [e]\n" + >+ " 24 iload_2 [n]\n" + >+ " 25 iconst_1\n" + >+ " 26 if_icmpne 32\n" + >+ " 29 goto 45\n" + >+ " 32 aload 6 [e]\n" + >+ " 34 invokevirtual X.value() : int [50]\n" + >+ " 37 istore_0 [val]\n" + >+ " 38 getstatic java.lang.System.out : java.io.PrintStream [52]\n" + >+ " 41 iload_0 [val]\n" + >+ " 42 invokevirtual java.io.PrintStream.println(int) : void [58]\n" + >+ " 45 iinc 4 1 [i]\n" + >+ " 48 iload 4 [i]\n" + >+ " 50 iload 5 [max]\n" + >+ " 52 if_icmplt 18\n" + >+ " 55 iload_1 [res]\n" + >+ " 56 ireturn\n" + >+ " Line numbers:\n" + >+ " [pc: 0, line: 14]\n" + >+ " [pc: 2, line: 15]\n" + >+ " [pc: 4, line: 16]\n" + >+ " [pc: 8, line: 17]\n" + >+ " [pc: 18, line: 18]\n" + >+ " [pc: 24, line: 19]\n" + >+ " [pc: 29, line: 20]\n" + >+ " [pc: 32, line: 22]\n" + >+ " [pc: 38, line: 23]\n" + >+ " [pc: 45, line: 17]\n" + >+ " [pc: 55, line: 25]\n" + >+ " Local variable table:\n" + >+ " [pc: 38, pc: 45] local: val index: 0 type: int\n" + >+ " [pc: 2, pc: 57] local: res index: 1 type: int\n" + >+ " [pc: 4, pc: 57] local: n index: 2 type: int\n" + >+ " [pc: 8, pc: 57] local: vals index: 3 type: X[]\n" + >+ " [pc: 11, pc: 55] local: i index: 4 type: int\n" + >+ " [pc: 15, pc: 55] local: max index: 5 type: int\n" + >+ " [pc: 24, pc: 45] local: e index: 6 type: X\n" + >+ " Stack map table: number of frames 4\n" + >+ " [pc: 18, full, stack: {}, locals: {_, int, int, X[], int, int}]\n" + >+ " [pc: 32, append: {X}]\n" + >+ " [pc: 45, chop 1 local(s)]\n" + >+ " [pc: 48, same]\n"; >+ >+ int index = actualOutput.indexOf(expectedOutput); >+ if (index == -1 || expectedOutput.length() == 0) { >+ System.out.println(Util.displayString(actualOutput, 2)); >+ } >+ if (index == -1) { >+ assertEquals("Wrong contents", expectedOutput, actualOutput); >+ } >+ } >+ >+ public void test016() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "public enum X {\n" + >+ " a1(1), a2(5), a3(11);\n" + >+ " int value;\n" + >+ " X(int a) {\n" + >+ " value = a;\n" + >+ " }\n" + >+ " int value () {\n" + >+ " return value;\n" + >+ " }\n" + >+ " public static void main(String argv[]) {\n" + >+ " }\n" + >+ " public static int foo() {\n" + >+ " int val;\n" + >+ " int res = 0;\n" + >+ " int n = 0;\n" + >+ " for (X e : X.values()) {\n" + >+ " if ( n == 1) {\n" + >+ " continue;\n" + >+ " }\n" + >+ " val = e.value();\n" + >+ " System.out.println(val);\n" + >+ " }\n" + >+ " return res;\n" + >+ " }\n" + >+ "}", >+ }, >+ ""); >+ >+ ClassFileBytesDisassembler disassembler = ToolFactory.createDefaultClassFileBytesDisassembler(); >+ String actualOutput = null; >+ try { >+ byte[] classFileBytes = org.eclipse.jdt.internal.compiler.util.Util.getFileByteContent(new File(OUTPUT_DIR + File.separator +"X.class")); >+ actualOutput = >+ disassembler.disassemble( >+ classFileBytes, >+ "\n", >+ ClassFileBytesDisassembler.DETAILED); >+ } catch (org.eclipse.jdt.core.util.ClassFormatException e) { >+ assertTrue("ClassFormatException", false); >+ } catch (IOException e) { >+ assertTrue("IOException", false); >+ } >+ >+ String expectedOutput = >+ " // Method descriptor #40 ()I\n" + >+ " // Stack: 2, Locals: 7\n" + >+ " public static int foo();\n" + >+ " 0 iconst_0\n" + >+ " 1 istore_1 [res]\n" + >+ " 2 iconst_0\n" + >+ " 3 istore_2 [n]\n" + >+ " 4 invokestatic X.values() : X[] [46]\n" + >+ " 7 astore 6\n" + >+ " 9 iconst_0\n" + >+ " 10 istore 4\n" + >+ " 12 aload 6\n" + >+ " 14 arraylength\n" + >+ " 15 istore 5\n" + >+ " 17 goto 49\n" + >+ " 20 aload 6\n" + >+ " 22 iload 4\n" + >+ " 24 aaload\n" + >+ " 25 astore_3 [e]\n" + >+ " 26 iload_2 [n]\n" + >+ " 27 iconst_1\n" + >+ " 28 if_icmpne 34\n" + >+ " 31 goto 46\n" + >+ " 34 aload_3 [e]\n" + >+ " 35 invokevirtual X.value() : int [50]\n" + >+ " 38 istore_0 [val]\n" + >+ " 39 getstatic java.lang.System.out : java.io.PrintStream [52]\n" + >+ " 42 iload_0 [val]\n" + >+ " 43 invokevirtual java.io.PrintStream.println(int) : void [58]\n" + >+ " 46 iinc 4 1\n" + >+ " 49 iload 4\n" + >+ " 51 iload 5\n" + >+ " 53 if_icmplt 20\n" + >+ " 56 iload_1 [res]\n" + >+ " 57 ireturn\n" + >+ " Line numbers:\n" + >+ " [pc: 0, line: 14]\n" + >+ " [pc: 2, line: 15]\n" + >+ " [pc: 4, line: 16]\n" + >+ " [pc: 26, line: 17]\n" + >+ " [pc: 31, line: 18]\n" + >+ " [pc: 34, line: 20]\n" + >+ " [pc: 39, line: 21]\n" + >+ " [pc: 46, line: 16]\n" + >+ " [pc: 56, line: 23]\n" + >+ " Local variable table:\n" + >+ " [pc: 39, pc: 46] local: val index: 0 type: int\n" + >+ " [pc: 2, pc: 58] local: res index: 1 type: int\n" + >+ " [pc: 4, pc: 58] local: n index: 2 type: int\n" + >+ " [pc: 26, pc: 46] local: e index: 3 type: X\n" + >+ " Stack map table: number of frames 4\n" + >+ " [pc: 20, full, stack: {}, locals: {_, int, int, _, int, int, X[]}]\n" + >+ " [pc: 34, full, stack: {}, locals: {_, int, int, X, int, int, X[]}]\n" + >+ " [pc: 46, full, stack: {}, locals: {_, int, int, _, int, int, X[]}]\n" + >+ " [pc: 49, same]\n"; >+ >+ int index = actualOutput.indexOf(expectedOutput); >+ if (index == -1 || expectedOutput.length() == 0) { >+ System.out.println(Util.displayString(actualOutput, 2)); >+ } >+ if (index == -1) { >+ assertEquals("Wrong contents", expectedOutput, actualOutput); >+ } >+ } >+ >+ public void test017() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "public class X {\n" + >+ " public static void main(String argv[]) {\n" + >+ " int i;\n" + >+ " \n" + >+ " switch (i = 0) {\n" + >+ " case 0 :\n" + >+ " i = 1;\n" + >+ " break;\n" + >+ " default :\n" + >+ " ;\n" + >+ " }\n" + >+ " System.out.print(i);\n" + >+ " }\n" + >+ "}", >+ }, >+ "1"); >+ >+ ClassFileBytesDisassembler disassembler = ToolFactory.createDefaultClassFileBytesDisassembler(); >+ String actualOutput = null; >+ try { >+ byte[] classFileBytes = org.eclipse.jdt.internal.compiler.util.Util.getFileByteContent(new File(OUTPUT_DIR + File.separator +"X.class")); >+ actualOutput = >+ disassembler.disassemble( >+ classFileBytes, >+ "\n", >+ ClassFileBytesDisassembler.DETAILED); >+ } catch (org.eclipse.jdt.core.util.ClassFormatException e) { >+ assertTrue("ClassFormatException", false); >+ } catch (IOException e) { >+ assertTrue("IOException", false); >+ } >+ >+ String expectedOutput = >+ " // Method descriptor #15 ([Ljava/lang/String;)V\n" + >+ " // Stack: 2, Locals: 2\n" + >+ " public static void main(java.lang.String[] argv);\n" + >+ " 0 iconst_0\n" + >+ " 1 dup\n" + >+ " 2 istore_1 [i]\n" + >+ " 3 tableswitch default: 22\n" + >+ " case 0: 20\n" + >+ " 20 iconst_1\n" + >+ " 21 istore_1 [i]\n" + >+ " 22 getstatic java.lang.System.out : java.io.PrintStream [16]\n" + >+ " 25 iload_1 [i]\n" + >+ " 26 invokevirtual java.io.PrintStream.print(int) : void [22]\n" + >+ " 29 return\n" + >+ " Line numbers:\n" + >+ " [pc: 0, line: 5]\n" + >+ " [pc: 20, line: 7]\n" + >+ " [pc: 22, line: 12]\n" + >+ " [pc: 29, line: 13]\n" + >+ " Local variable table:\n" + >+ " [pc: 0, pc: 30] local: argv index: 0 type: java.lang.String[]\n" + >+ " [pc: 3, pc: 30] local: i index: 1 type: int\n" + >+ " Stack map table: number of frames 2\n" + >+ " [pc: 20, append: {int}]\n" + >+ " [pc: 22, same]\n"; >+ >+ int index = actualOutput.indexOf(expectedOutput); >+ if (index == -1 || expectedOutput.length() == 0) { >+ System.out.println(Util.displayString(actualOutput, 2)); >+ } >+ if (index == -1) { >+ assertEquals("Wrong contents", expectedOutput, actualOutput); >+ } >+ } >+ >+ public void test018() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "import java.util.*;\n" + >+ "\n" + >+ "interface Sequence<Value_Type> extends Iterable<Value_Type>{\n" + >+ "\n" + >+ " Value_Type get(int i);\n" + >+ " int length();\n" + >+ " Value_Type set(int i, Value_Type value);\n" + >+ "}\n" + >+ "\n" + >+ "class ArraySequence<Value_Type> implements Sequence<Value_Type> {\n" + >+ "\n" + >+ " public ArraySequence(int length) {}\n" + >+ " public Value_Type get(int i) {\n" + >+ " return null;\n" + >+ " }\n" + >+ " public int length() {\n" + >+ " return 0;\n" + >+ " }\n" + >+ " public Value_Type set(int i, Value_Type value) {\n" + >+ " return value;\n" + >+ " }\n" + >+ " public Iterator<Value_Type> iterator() {\n" + >+ " return null;\n" + >+ " }\n" + >+ "}\n" + >+ "\n" + >+ "class BirBlock {\n" + >+ " void setRole(IrBlock.Role role) {}\n" + >+ "}\n" + >+ "\n" + >+ "class CatchChain {\n" + >+ " int dispatcherAddress() {\n" + >+ " return 0;\n" + >+ " }\n" + >+ "}\n" + >+ "\n" + >+ "class ExceptionHandlerInfo {\n" + >+ " int handlerProgramCounter() {\n" + >+ " return 0;\n" + >+ " }\n" + >+ "}\n" + >+ "\n" + >+ "interface IrBlock {\n" + >+ " enum Role {\n" + >+ " EXCEPTION_DISPATCHER\n" + >+ " }\n" + >+ "}\n" + >+ "\n" + >+ "class ClassMethodActor {\n" + >+ " Sequence<ExceptionHandlerInfo> exceptionHandlerInfos() {\n" + >+ " return null;\n" + >+ " }\n" + >+ "}\n" + >+ "\n" + >+ "public class X {\n" + >+ "\n" + >+ " private Sequence<CatchChain> _catchChains;\n" + >+ " private ClassMethodActor _classMethodActor;\n" + >+ "\n" + >+ " public Sequence<BirBlock> getExceptionDispatchers(final BirBlock[] blockMap) {\n" + >+ " final ArraySequence<BirBlock> dispatchers = new ArraySequence<BirBlock>(_catchChains.length());\n" + >+ " for (int i = 0; i < _catchChains.length(); i++) {\n" + >+ " final BirBlock dispatcher = blockMap[_catchChains.get(i).dispatcherAddress()];\n" + >+ " dispatcher.setRole(IrBlock.Role.EXCEPTION_DISPATCHER);\n" + >+ " dispatchers.set(i, dispatcher);\n" + >+ " }\n" + >+ " for (ExceptionHandlerInfo exceptionHandlerInfo : _classMethodActor.exceptionHandlerInfos()) {\n" + >+ " blockMap[exceptionHandlerInfo.handlerProgramCounter()].setRole(IrBlock.Role.EXCEPTION_DISPATCHER);\n" + >+ " }\n" + >+ " return dispatchers;\n" + >+ " }\n" + >+ " public static void main(String[] args) {\n" + >+ " System.out.print(\"SUCCESS\");\n" + >+ " }\n" + >+ "}", >+ }, >+ "SUCCESS"); >+ } >+ >+ public void test019() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "final public class X\n" + >+ "{\n" + >+ " final class MyClass\n" + >+ " {\n" + >+ " void method1(final String s)\n" + >+ " {\n" + >+ " }\n" + >+ " }\n" + >+ "\n" + >+ " Object method1()\n" + >+ " {\n" + >+ " try\n" + >+ " {\n" + >+ " final MyClass myClass = null;\n" + >+ "\n" + >+ " try\n" + >+ " {\n" + >+ " return null;\n" + >+ " }\n" + >+ " catch (final Throwable ex)\n" + >+ " {\n" + >+ " myClass.method1(this == null ? \"\" : \"\");\n" + >+ " }\n" + >+ "\n" + >+ " return null;\n" + >+ " }\n" + >+ " finally\n" + >+ " {\n" + >+ " {\n" + >+ " }\n" + >+ " }\n" + >+ " }\n" + >+ " public static void main(String[] args) {\n" + >+ " System.out.print(\"SUCCESS\");\n" + >+ " }\n" + >+ "}", >+ }, >+ "SUCCESS"); >+ } >+ public void test020() { >+ this.runConformTest( >+ new String[] { >+ "X.java", >+ "import java.util.*;\n" + >+ "public class X {\n" + >+ " public static Map make(boolean sorted) {\n" + >+ " return (sorted) ? new TreeMap() : new HashMap();\n" + >+ " }\n" + >+ " public static void main(String[] args) {\n" + >+ " make(false);\n" + >+ " System.out.print(\"SUCCESS\");\n" + >+ " }\n" + >+ "}", >+ }, >+ "SUCCESS"); >+ } > } >Index: src/org/eclipse/jdt/core/tests/compiler/regression/SwitchTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/SwitchTest.java,v >retrieving revision 1.12 >diff -u -r1.12 SwitchTest.java >--- src/org/eclipse/jdt/core/tests/compiler/regression/SwitchTest.java 3 Apr 2006 14:46:13 -0000 1.12 >+++ src/org/eclipse/jdt/core/tests/compiler/regression/SwitchTest.java 23 Aug 2006 15:29:54 -0000 >@@ -320,7 +320,7 @@ > " 42 invokevirtual java.io.PrintStream.println(java.lang.String) : void [24]\n" + > " 45 return\n" + > " Exception Table:\n" + >- " [pc: 2, pc: 36] -> 36 when : java.lang.Exception\n" + >+ " [pc: 2, pc: 33] -> 36 when : java.lang.Exception\n" + > " Line numbers:\n" + > " [pc: 0, line: 3]\n" + > " [pc: 2, line: 5]\n" + >Index: src/org/eclipse/jdt/core/tests/runtime/StandardVMLauncher.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/runtime/StandardVMLauncher.java,v >retrieving revision 1.14 >diff -u -r1.14 StandardVMLauncher.java >--- src/org/eclipse/jdt/core/tests/runtime/StandardVMLauncher.java 10 May 2006 18:07:26 -0000 1.14 >+++ src/org/eclipse/jdt/core/tests/runtime/StandardVMLauncher.java 23 Aug 2006 15:29:54 -0000 >@@ -114,6 +114,12 @@ > } > } > >+ String vmVersion = System.getProperty("java.vm.version"); >+ if (vmVersion != null && vmVersion.startsWith("1.6")) { >+ commandLine.addElement("-XX:-FailOverToOldVerifier"); >+ commandLine.addElement("-Xverify:all"); >+ } >+ > // debug mode > if (this.debugPort != -1) { > commandLine.addElement("-Xdebug");
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 145397
:
43501
|
43656
|
45323
|
48472
| 48473