Community
Participate
Working Groups
Build Identifier: M20110210-1200 I´ve written a Interface that declare two functions that override implemented functions in java, wich themselfs are not defined yet(See screenshot). A unhandled exception occurs->the error log will be added. Eclipse 3.6.2 was used and the openjdk6u20 on openSUSE11.4. Eclipse is executed from your download package and not installed with yast2. Reproducible: Didn't try Steps to Reproduce: 1.figuring unskilled around 2. 3.
Created attachment 196890 [details] I´ve used the quickfix Add unimplemented methods
Created attachment 196891 [details] the error log-stacktracke
To reproduce, paste this to Package Explorer and then apply the "Add unimplemented methods" quick fix on Test2: //------------------------------------------------------------------ public interface ITest { // public void write(int wert); // public int read(); public void foo(); } public class Test implements ITest { @Override public void write(int wert) { // TODO Auto-generated method stub } @Override public int read() { // TODO Auto-generated method stub return 0; } } class Test2 implements ITest //------------------------------------------------------------------ Moving to JDT/Core to add more protection (similar to bug 272711).
If you plan to include a fix for this in 3.8 M7, please adjust the target suitably, so it becomes easier to track.
Will not be able to contain this in 3.8.
Relevant stack trace: java.lang.IllegalArgumentException: Document does not match the AST at org.eclipse.jdt.internal.core.dom.rewrite.ASTRewriteAnalyzer.handleException(ASTRewriteAnalyzer.java:3583) at org.eclipse.jdt.internal.core.dom.rewrite.ASTRewriteAnalyzer.getPosAfterLeftBrace(ASTRewriteAnalyzer.java:1159) at org.eclipse.jdt.internal.core.dom.rewrite.ASTRewriteAnalyzer.visit(ASTRewriteAnalyzer.java:1605) at org.eclipse.jdt.core.dom.TypeDeclaration.accept0(TypeDeclaration.java:467) at org.eclipse.jdt.core.dom.ASTNode.accept(ASTNode.java:2480) at org.eclipse.jdt.core.dom.rewrite.ASTRewrite.internalRewriteAST(ASTRewrite.java:271) at org.eclipse.jdt.core.dom.rewrite.ASTRewrite.rewriteAST(ASTRewrite.java:260) at org.eclipse.jdt.internal.corext.refactoring.structure.CompilationUnitRewrite.attachChange(CompilationUnitRewrite.java:271) ... Caused by: org.eclipse.core.runtime.CoreException: End Of File at org.eclipse.jdt.internal.core.dom.rewrite.TokenScanner.readNext(TokenScanner.java:92) at org.eclipse.jdt.internal.core.dom.rewrite.TokenScanner.readNext(TokenScanner.java:111) at org.eclipse.jdt.internal.core.dom.rewrite.ASTRewriteAnalyzer.getPosAfterLeftBrace(ASTRewriteAnalyzer.java:1154) ... 45 more
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie.