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 58769 Details for
Bug 173853
[recovery] Recovery add an unnecessary default contructor
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Proposed fix
bug173853_001.txt (text/plain), 33.62 KB, created by
David Audel
on 2007-02-12 09:32:27 EST
(
hide
)
Description:
Proposed fix
Filename:
MIME Type:
Creator:
David Audel
Created:
2007-02-12 09:32:27 EST
Size:
33.62 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.core.tests.compiler >Index: src/org/eclipse/jdt/core/tests/compiler/parser/CompletionParserTest2.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/CompletionParserTest2.java,v >retrieving revision 1.41 >diff -u -r1.41 CompletionParserTest2.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/CompletionParserTest2.java 19 Jan 2007 17:06:39 -0000 1.41 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/CompletionParserTest2.java 12 Feb 2007 14:29:06 -0000 >@@ -7213,8 +7213,6 @@ > " }\n" + > " void foo() {\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void bar() {\n" + > " a[<CompleteOnName:zzz>];\n" + > " }\n" + >@@ -7488,8 +7486,6 @@ > " {\n" + > " <CompleteOnName:>;\n" + > " }\n" + >- " () {\n" + >- " }\n" + > " };\n" + > " }\n" + > "}\n"; >@@ -7596,9 +7592,6 @@ > String expectedUnitDisplayString = > "public class X {\n" + > " Object o = new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " {\n" + > " Exception e;\n" + >@@ -7780,8 +7773,6 @@ > " }\n" + > " void foo() {\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void bar() {\n" + > " <CompleteOnMessageSend:super.zzz()>;\n" + > " }\n" + >@@ -7856,15 +7847,11 @@ > " }\n" + > " public void foo() {\n" + > " new Y() {\n" + >- " () {\n" + >- " }\n" + > " public void bar() {\n" + > " new Z() {\n" + > " <CompleteOnFieldName:void to>;\n" + > " {\n" + > " }\n" + >- " () {\n" + >- " }\n" + > " };\n" + > " }\n" + > " };\n" + >@@ -7941,9 +7928,6 @@ > String expectedUnitDisplayString = > "public class X {\n" + > " private Object var = new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " public void foo(Object e) {\n" + > " <CompleteOnName:e.>;\n" + > " }\n" + >@@ -8056,8 +8040,6 @@ > " }\n" + > " public void foo() {\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " public void toto() {\n" + > " <CompleteOnKeyword:instanceof>;\n" + > " }\n" + >@@ -8447,8 +8429,6 @@ > " }\n" + > " public void foo() {\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void bar() {\n" + > " (titi & <CompleteOnName:ZZ>);\n" + > " }\n" + >@@ -8613,9 +8593,6 @@ > String expectedUnitDisplayString = > "public class X {\n" + > " Object var = new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void bar() {\n" + > " }\n" + > " void foo() {\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/CompletionParserTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/CompletionParserTest.java,v >retrieving revision 1.28 >diff -u -r1.28 CompletionParserTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/CompletionParserTest.java 19 Jan 2007 17:06:39 -0000 1.28 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/CompletionParserTest.java 12 Feb 2007 14:29:05 -0000 >@@ -1131,8 +1131,6 @@ > " }\n" + > " void foo() {\n" + > " new TestCase(\"error\") {\n" + >- " () {\n" + >- " }\n" + > " protected void runTest() {\n" + > " Vector v11111;\n" + > " <CompleteOnName:v>;\n" + >@@ -1174,8 +1172,6 @@ > " void foo() {\n" + > " new TestCase(\"error\") {\n" + > " <CompleteOnType:v>;\n" + >- " () {\n" + >- " }\n" + > " runTest() {\n" + > " }\n" + > " };\n" + >@@ -1223,8 +1219,6 @@ > " <CompleteOnFieldName:void r>;\n" + > " {\n" + > " }\n" + >- " () {\n" + >- " }\n" + > " };\n" + > " }\n" + > "}\n"; >@@ -1264,8 +1258,6 @@ > " }\n" + > " void foo() {\n" + > " new TestCase(\"error\") {\n" + >- " () {\n" + >- " }\n" + > " protected void runTest() {\n" + > " <CompleteOnName:V>;\n" + > " }\n" + >@@ -1308,8 +1300,6 @@ > " }\n" + > " void foo() {\n" + > " new TestCase(\"error\") {\n" + >- " () {\n" + >- " }\n" + > " protected void runTest() {\n" + > " Vector v11111;\n" + > " <CompleteOnName:v>;\n" + >@@ -2119,8 +2109,6 @@ > " public static void main(String[] args) {\n" + > " Object l;\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " public void handleEvent(String[] event) {\n" + > " String s;\n" + > " <CompleteOnName:s.>;\n" + >@@ -2175,8 +2163,6 @@ > " public static void main(String[] args) {\n" + > " Object l;\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " public void handleEvent(String[] event) {\n" + > " String s;\n" + > " {\n" + >@@ -2233,8 +2219,6 @@ > " public static void main(String[] args) {\n" + > " Object l;\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " public void handleEvent(String[] event) {\n" + > " String s;\n" + > " {\n" + >@@ -6257,8 +6241,6 @@ > " }\n" + > " void foo() {\n" + > " new java.io.File(\"error\") {\n" + >- " () {\n" + >- " }\n" + > " protected void runTest() {\n" + > " Vector v11111;\n" + > " <CompleteOnName:v>;\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/NameReferenceCompletionTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/NameReferenceCompletionTest.java,v >retrieving revision 1.12 >diff -u -r1.12 NameReferenceCompletionTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/NameReferenceCompletionTest.java 29 Mar 2006 03:50:23 -0000 1.12 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/NameReferenceCompletionTest.java 12 Feb 2007 14:29:08 -0000 >@@ -206,8 +206,6 @@ > " final int codeAssistTarget;\n" + > " Thread t;\n" + > " new Thread() {\n" + >- " () {\n" + >- " }\n" + > " public void run() {\n" + > " <CompleteOnName:codeAss>;\n" + > " }\n" + >@@ -290,8 +288,6 @@ > " }\n" + > " void foo() {\n" + > " new Runnable() {\n" + >- " () {\n" + >- " }\n" + > " public void run() {\n" + > " <CompleteOnName:>;\n" + > " }\n" + >@@ -530,9 +526,6 @@ > // expectedUnitDisplayString: > "class Bar {\n" + > " Object o = new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " <CompleteOnName:xyz>;\n" + > " }\n" + >@@ -607,8 +600,6 @@ > " }\n" + > " void foo() {\n" + > " new X() {\n" + >- " () {\n" + >- " }\n" + > " void fuzz() {\n" + > " <CompleteOnName:x.>;\n" + > " }\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/SelectionTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/SelectionTest.java,v >retrieving revision 1.18 >diff -u -r1.18 SelectionTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/SelectionTest.java 29 Mar 2006 03:50:24 -0000 1.18 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/SelectionTest.java 12 Feb 2007 14:29:09 -0000 >@@ -743,9 +743,6 @@ > > String expectedCompletionNodeToString = > "<SelectOnAllocationExpression:new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > "}>"; > String completionIdentifier = "Object"; > String expectedUnitDisplayString = >@@ -754,9 +751,6 @@ > " }\n" + > " int foo() {\n" + > " <SelectOnAllocationExpression:new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " }>;\n" + > " }\n" + > "}\n"; >@@ -1118,8 +1112,6 @@ > " }\n" + > " Object foo() {\n" + > " new X() {\n" + >- " () {\n" + >- " }\n" + > " Object bar() {\n" + > " <SelectOnQualifiedSuper:G.super>;\n" + > " }\n" + >@@ -2137,18 +2129,12 @@ > String selection = "X"; > > String expectedCompletionNodeToString = "<SelectOnAllocationExpression:new X() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > "}>"; > > String completionIdentifier = "X"; > String expectedUnitDisplayString = > "public class X {\n"+ > " X x = <SelectOnAllocationExpression:new X() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " }>;\n"+ > " public X() {\n"+ > " }\n"+ >@@ -2198,8 +2184,6 @@ > " }\n" + > " void foo() {\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void bar() {\n" + > " <SelectOnMessageSend:bar2()>;\n" + > " }\n" + >@@ -2257,12 +2241,8 @@ > " }\n" + > " void foo() {\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void foo0() {\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void bar() {\n" + > " <SelectOnMessageSend:bar2()>;\n" + > " }\n" + >@@ -2323,12 +2303,8 @@ > " }\n" + > " void foo() {\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void foo0() {\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void bar() {\n" + > " <SelectOnMessageSend:bar2()>;\n" + > " }\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/EnumDietRecoveryTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/EnumDietRecoveryTest.java,v >retrieving revision 1.7 >diff -u -r1.7 EnumDietRecoveryTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/EnumDietRecoveryTest.java 29 Mar 2006 03:50:24 -0000 1.7 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/EnumDietRecoveryTest.java 12 Feb 2007 14:29:08 -0000 >@@ -313,9 +313,6 @@ > "public enum X {\n" + > " A(10),\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " },\n" + > " public X() {\n" + > " }\n" + >@@ -328,9 +325,6 @@ > "public enum X {\n" + > " A(10),\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " },\n" + > " public X() {\n" + > " super();\n" + >@@ -369,9 +363,6 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + >@@ -385,9 +376,6 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + >@@ -429,9 +417,6 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + >@@ -445,9 +430,6 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + >@@ -489,16 +471,10 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + > " public X() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " },\n" + > " public X() {\n" + > " }\n" + >@@ -510,16 +486,10 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + > " public X() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " },\n" + > " public X() {\n" + > " super();\n" + >@@ -559,16 +529,10 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + > " X() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " },\n" + > " public X() {\n" + > " }\n" + >@@ -580,16 +544,10 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + > " X() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " },\n" + > " public X() {\n" + > " super();\n" + >@@ -681,9 +639,6 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + >@@ -697,9 +652,6 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + >@@ -741,9 +693,6 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " void bar() {\n" + >@@ -759,9 +708,7 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + >+ > " void foo() {\n" + > " }\n" + > " void bar() {\n" + >@@ -805,9 +752,6 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " X() {\n" + >@@ -823,9 +767,6 @@ > "package a;\n" + > "public enum X {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " X() {\n" + >@@ -1001,9 +942,6 @@ > " }\n" + > " enum Z {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + >@@ -1031,9 +969,6 @@ > " }\n" + > " enum Z {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + >@@ -1088,9 +1023,6 @@ > String expectedDietUnitToString = > "public enum Enum1 {\n" + > " BLEU() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + >@@ -1106,9 +1038,6 @@ > String expectedDietPlusBodyUnitToString = > "public enum Enum1 {\n" + > " BLEU() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/EnumCompletionParserTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/EnumCompletionParserTest.java,v >retrieving revision 1.9 >diff -u -r1.9 EnumCompletionParserTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/EnumCompletionParserTest.java 29 Mar 2006 03:50:23 -0000 1.9 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/EnumCompletionParserTest.java 12 Feb 2007 14:29:08 -0000 >@@ -525,9 +525,6 @@ > String expectedUnitDisplayString = > "public enum Test {\n" + > " A() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " <CompleteOnName:zzz>;\n" + > " }\n" + >@@ -570,9 +567,6 @@ > "public enum Test {\n" + > " B(),\n" + > " A() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " <CompleteOnName:zzz>;\n" + > " }\n" + >@@ -616,9 +610,6 @@ > "public enum Test {\n" + > " B(),\n" + > " A() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " <CompleteOnName:zzz>;\n" + > " }\n" + >@@ -663,16 +654,10 @@ > String expectedUnitDisplayString = > "public enum Test {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + > " A() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " <CompleteOnName:zzz>;\n" + > " }\n" + >@@ -718,16 +703,10 @@ > String expectedUnitDisplayString = > "public enum Test {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + > " A() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " <CompleteOnName:zzz>;\n" + > " }\n" + >@@ -774,16 +753,10 @@ > String expectedUnitDisplayString = > "public enum Test {\n" + > " B() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " },\n" + > " A() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " <CompleteOnName:zzz>;\n" + > " }\n" + >@@ -823,9 +796,6 @@ > "public enum Enum1 {\n" + > " A() {\n" + > " <CompleteOnType:tos>;\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " },\n" + > " public Enum1() {\n" + > " }\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/CompletionRecoveryTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/CompletionRecoveryTest.java,v >retrieving revision 1.15 >diff -u -r1.15 CompletionRecoveryTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/CompletionRecoveryTest.java 29 Mar 2006 03:50:24 -0000 1.15 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/CompletionRecoveryTest.java 12 Feb 2007 14:29:06 -0000 >@@ -375,9 +375,6 @@ > "public class VA {\n" + > " Object o1 = new Object() {\n" + > " <CompleteOnType:V>;\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo2() {\n" + > " }\n" + > " };\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/StatementRecoveryTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/StatementRecoveryTest.java,v >retrieving revision 1.9 >diff -u -r1.9 StatementRecoveryTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/StatementRecoveryTest.java 16 Oct 2006 08:40:57 -0000 1.9 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/StatementRecoveryTest.java 12 Feb 2007 14:29:09 -0000 >@@ -1861,9 +1861,6 @@ > " void foo() {\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " }\n" + > " };\n" + >@@ -1934,9 +1931,6 @@ > " void foo() {\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void bar() {\n" + > " }\n" + > " };\n" + >@@ -2012,18 +2006,12 @@ > " void foo() {\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void bar() {\n" + > " }\n" + > " };\n" + > " System.out.println();\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void bar() {\n" + > " }\n" + > " };\n" + >@@ -2096,9 +2084,6 @@ > " void foo() {\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " System.out.println();\n" + > " }\n" + >@@ -2172,9 +2157,6 @@ > " void foo() {\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " System.out.println();\n" + > " }\n" + >@@ -2255,9 +2237,6 @@ > " void foo() {\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " System.out.println();\n" + > " }\n" + >@@ -2265,9 +2244,6 @@ > " System.out.println();\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " System.out.println();\n" + > " }\n" + >@@ -2345,9 +2321,6 @@ > " void foo() {\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " System.out.println();\n" + > " if (true)\n" + >@@ -2430,9 +2403,6 @@ > " void foo() {\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " System.out.println();\n" + > " if (true)\n" + >@@ -2520,9 +2490,6 @@ > " void foo() {\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " System.out.println();\n" + > " if (true)\n" + >@@ -2617,9 +2584,6 @@ > " void foo() {\n" + > " System.out.println();\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " System.out.println();\n" + > " if (true)\n" + >@@ -2714,9 +2678,6 @@ > " void foo() {\n" + > " System.out.println();\n" + > " bar(new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " System.out.println();\n" + > " if (true)\n" + >@@ -2870,9 +2831,6 @@ > " }\n" + > " void foo() {\n" + > " new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " System.out.println();\n" + > " }\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/InnerTypeCompletionTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/InnerTypeCompletionTest.java,v >retrieving revision 1.10 >diff -u -r1.10 InnerTypeCompletionTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/InnerTypeCompletionTest.java 29 Mar 2006 03:50:23 -0000 1.10 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/InnerTypeCompletionTest.java 12 Feb 2007 14:29:08 -0000 >@@ -50,8 +50,6 @@ > " void foo() {\n" + > " Object o;\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void buzz() {\n" + > " int i = <CompleteOnMemberAccess:fred().x>;\n" + > " }\n" + >@@ -94,8 +92,6 @@ > " void foo() {\n" + > " Object o;\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void buzz() {\n" + > " int i = <CompleteOnMemberAccess:fred().x>;\n" + > " }\n" + >@@ -139,8 +135,6 @@ > " Object o;\n" + > " new Object() {\n" + > " int field;\n" + >- " () {\n" + >- " }\n" + > " void buzz() {\n" + > " int i = <CompleteOnMemberAccess:fred().x>;\n" + > " }\n" + >@@ -183,8 +177,6 @@ > " int i;\n" + > " Object o;\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void buzz() {\n" + > " int i = <CompleteOnMemberAccess:fred().x>;\n" + > " }\n" + >@@ -227,8 +219,6 @@ > " void foo() {\n" + > " Object o;\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void fuzz() {\n" + > " }\n" + > " void buzz() {\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/LabelStatementCompletionTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/LabelStatementCompletionTest.java,v >retrieving revision 1.12 >diff -u -r1.12 LabelStatementCompletionTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/LabelStatementCompletionTest.java 8 Jun 2006 13:07:59 -0000 1.12 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/LabelStatementCompletionTest.java 12 Feb 2007 14:29:08 -0000 >@@ -313,8 +313,6 @@ > " {\n" + > " Object o;\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void fred() {\n" + > " {\n" + > " <CompleteOnName:X>;\n" + >@@ -368,8 +366,6 @@ > " {\n" + > " Object o;\n" + > " new Object() {\n" + >- " () {\n" + >- " }\n" + > " void fred() {\n" + > " {\n" + > " <CompleteOnName:X>;\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/DietCompletionTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/DietCompletionTest.java,v >retrieving revision 1.14 >diff -u -r1.14 DietCompletionTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/DietCompletionTest.java 29 Mar 2006 03:50:23 -0000 1.14 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/DietCompletionTest.java 12 Feb 2007 14:29:07 -0000 >@@ -2007,9 +2007,6 @@ > String expectedUnitDisplayString = > "class X {\n" + > " Object o = new Object() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void foo() {\n" + > " String x;\n" + > " <CompleteOnName:x.index>;\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/ReferenceTypeCompletionTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/ReferenceTypeCompletionTest.java,v >retrieving revision 1.13 >diff -u -r1.13 ReferenceTypeCompletionTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/ReferenceTypeCompletionTest.java 19 Jan 2007 17:06:39 -0000 1.13 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/ReferenceTypeCompletionTest.java 12 Feb 2007 14:29:09 -0000 >@@ -47,8 +47,6 @@ > " void foo() {\n" + > " new X() {\n" + > " <CompleteOnType:p>;\n" + >- " () {\n" + >- " }\n" + > " void bar() {\n" + > " }\n" + > " };\n" + >Index: src/org/eclipse/jdt/core/tests/compiler/parser/DietRecoveryTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/DietRecoveryTest.java,v >retrieving revision 1.49 >diff -u -r1.49 DietRecoveryTest.java >--- src/org/eclipse/jdt/core/tests/compiler/parser/DietRecoveryTest.java 16 Nov 2006 17:43:48 -0000 1.49 >+++ src/org/eclipse/jdt/core/tests/compiler/parser/DietRecoveryTest.java 12 Feb 2007 14:29:08 -0000 >@@ -2020,9 +2020,6 @@ > " System.out.println();\n" + > " new X() {\n" + > " public int h;\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " void baz() {\n" + > " }\n" + > " void bar() {\n" + >@@ -6094,9 +6091,6 @@ > " Shell shell = new Shell((((SWT.MENU | SWT.RESIZE) | SWT.TITLE) | SWT.H_SCROLL));\n" + > " StyledText text = new StyledText(shell, SWT.WRAP);\n" + > " shell.addListener(SWT.Resize, new Listener() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " public void handleEvent(Event e) {\n" + > " text.setBounds(shell.getClientArea());\n" + > " }\n" + >@@ -6107,9 +6101,6 @@ > " }\n" + > "});\n" + > " text.addLineStyleListener(new LineStyleListener() {\n" + >- " () {\n" + >- " super();\n" + >- " }\n" + > " public void lineGetStyle(LineStyleEvent event) {\n" + > " }\n" + > "});\n" + >#P org.eclipse.jdt.core.tests.model >Index: src/org/eclipse/jdt/core/tests/dom/ASTConverterTest2.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/dom/ASTConverterTest2.java,v >retrieving revision 1.174 >diff -u -r1.174 ASTConverterTest2.java >--- src/org/eclipse/jdt/core/tests/dom/ASTConverterTest2.java 8 Jun 2006 13:09:33 -0000 1.174 >+++ src/org/eclipse/jdt/core/tests/dom/ASTConverterTest2.java 12 Feb 2007 14:29:18 -0000 >@@ -5451,4 +5451,35 @@ > } > }); > } >+ >+ /** >+ * https://bugs.eclipse.org/bugs/show_bug.cgi?id=173853 >+ */ >+ public void test0607() throws CoreException { >+ ICompilationUnit workingCopy = null; >+ try { >+ workingCopy = getWorkingCopy( >+ "/Converter/src/X.java", >+ "public class X {\n" + >+ " void foo() {\n" + >+ " #\n" + >+ " /*start*/new Object() {\n" + >+ " }/*end*/;\n" + >+ " }\n" + >+ "}", >+ true/*resolve*/); >+ ASTNode string = buildAST(null, workingCopy, true, true); >+ assertEquals("Unexpected node type", ASTNode.CLASS_INSTANCE_CREATION, string.getNodeType()); >+ ClassInstanceCreation classInstanceCreation = (ClassInstanceCreation) string; >+ ITypeBinding resolveTypeBinding = classInstanceCreation.resolveTypeBinding(); >+ assertNotNull("Binding is null", resolveTypeBinding); >+ IMethodBinding[] declaredMethods = resolveTypeBinding.getDeclaredMethods(); >+ assertNotNull("Should have one method", declaredMethods); >+ assertEquals("Should have one method", 1, declaredMethods.length); >+ assertTrue("The method should be a default constructor", declaredMethods[0].isDefaultConstructor()); >+ } finally { >+ if (workingCopy != null) >+ workingCopy.discardWorkingCopy(); >+ } >+ } > } >\ No newline at end of file >#P org.eclipse.jdt.core >Index: compiler/org/eclipse/jdt/internal/compiler/ast/TypeDeclaration.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/ast/TypeDeclaration.java,v >retrieving revision 1.133 >diff -u -r1.133 TypeDeclaration.java >--- compiler/org/eclipse/jdt/internal/compiler/ast/TypeDeclaration.java 25 Jan 2007 18:10:51 -0000 1.133 >+++ compiler/org/eclipse/jdt/internal/compiler/ast/TypeDeclaration.java 12 Feb 2007 14:29:20 -0000 >@@ -399,6 +399,8 @@ > argumentsLength == 0 ? Binding.NO_PARAMETERS : argumentTypes, //arguments bindings > inheritedConstructorBinding.thrownExceptions, //exceptions > sourceType); //declaringClass >+ >+ constructor.binding.modifiers |= ExtraCompilerModifiers.AccIsDefaultConstructor; > > constructor.scope = new MethodScope(this.scope, constructor, true); > constructor.bindArguments(); >Index: compiler/org/eclipse/jdt/internal/compiler/parser/RecoveredType.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/parser/RecoveredType.java,v >retrieving revision 1.57 >diff -u -r1.57 RecoveredType.java >--- compiler/org/eclipse/jdt/internal/compiler/parser/RecoveredType.java 29 Mar 2006 02:47:34 -0000 1.57 >+++ compiler/org/eclipse/jdt/internal/compiler/parser/RecoveredType.java 12 Feb 2007 14:29:20 -0000 >@@ -421,7 +421,10 @@ > typeDeclaration.methods = methodDeclarations; > } else { > int kind = TypeDeclaration.kind(typeDeclaration.modifiers); >- if (!hasConstructor && kind != TypeDeclaration.INTERFACE_DECL && kind != TypeDeclaration.ANNOTATION_TYPE_DECL) {// if was already reduced, then constructor >+ if (!hasConstructor && >+ kind != TypeDeclaration.INTERFACE_DECL && >+ kind != TypeDeclaration.ANNOTATION_TYPE_DECL && >+ typeDeclaration.allocation == null) {// if was already reduced, then constructor > boolean insideFieldInitializer = false; > RecoveredElement parentElement = this.parent; > while (parentElement != null){
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 173853
: 58769