Summary: | StackOverflowError when pasting code | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Veronika Irvine <veronika_irvine> | ||||||
Component: | Core | Assignee: | David Audel <david_audel> | ||||||
Status: | VERIFIED FIXED | QA Contact: | |||||||
Severity: | normal | ||||||||
Priority: | P3 | CC: | daniel_megert, Tod_Creasey | ||||||
Version: | 3.0 | ||||||||
Target Milestone: | 3.0 M9 | ||||||||
Hardware: | PC | ||||||||
OS: | Windows XP | ||||||||
Whiteboard: | |||||||||
Attachments: |
|
Description
Veronika Irvine
Could you please provide the whole test case? Thanks. I will have to try and recreate it the steps. After the StackOverflow error, eclipse was not behaving correctly and had to be restarted. I had the class Browser.java (see attached). I selected the following: --start selection here webSite.addEventListener (OleWebBrowser.ProgressChange, new OleListener() { public void handleEvent(OleEvent event) -- end selection here (before "}") Then, I hit Ctrl+X, CTRL+Z, CTRL+S a few times and the error happened. I can't make it happen every time but if I play with the CTRL+X, CTRL+Z, CTRL+S, eventually it happens. I will also attach my preferences. Created attachment 5714 [details]
java file
Browser.java
Created attachment 5715 [details]
Veronika's preferences
Veronika's preferences
I think this has something to do with the recovery. Need to be backported to 2.1 once addressed. Simple test case 1) create X.java package p; public class X{ public void foo() { new Y() { public void bar() { switch (zzz){ case 1 : }; } new Z() { public void to<cursor>to() { } }); }); } } 2) do ctrl + space at cursor location Inside RecoveredType [public RecoveredElement add(TypeDeclaration memberTypeDeclaration, int bracketBalanceValue) { ... return lastMethod.add(typeDeclaration, bracketBalanceValue); ... }] must be [public RecoveredElement add(TypeDeclaration memberTypeDeclaration, int bracketBalanceValue) { ... return lastMethod.add(memberTypeDeclaration, bracketBalanceValue); ... }] Fixed and regression test added (CompletionParserTest2#test0138()) in 3.0 *** Bug 57067 has been marked as a duplicate of this bug. *** *** Bug 38098 has been marked as a duplicate of this bug. *** Backported and regression test added (CompletionParserTest2#test0130()) in 2.1 Verified in 200405180816 |