Community
Participate
Working Groups
1) open org.eclipse.jdt.tests.core.TypeHierarchyTests. 2) add an error in this class. 3) click on the Quick Fix light. StackTrace: at org.eclipse.jdt.internal.compiler.ast.BinaryExpression.resolveType (BinaryExpression.java:1638) at org.eclipse.jdt.internal.compiler.ast.BinaryExpression.resolveType (BinaryExpression.java:1638) at org.eclipse.jdt.internal.compiler.ast.BinaryExpression.resolveType ... (BinaryExpression.java:1638) at org.eclipse.jdt.internal.compiler.ast.BinaryExpression.resolveType (BinaryExpression.java:1638) at org.eclipse.jdt.internal.compiler.ast.BinaryExpression.resolveType (BinaryExpression.java:1638
Defer... DOM APIs should be protected.
There is some potential for this to occur in outliner. The DOM AST isn't able to treat multi string concatenations in one node. e.g. String s = "aaa" + "aab" + "aac" + .... + "zzz"; It should perform similar optimization as compiler does.
Actually, previous comment should have said that it has potential to occur in AST created during reconcile operation.
InfixExpression.extendedOperands allows multi-string concatenations etc. to be represented as broad, flat ASTs.
Olivier - pls verify that DOM AST had now support for handling these n-ary operations (should be InfixExpression.extendedOperands). Also check that DOM AST constructed during #reconcile operation is indeed building such a flavor of an AST.
Suspecting this to cause the fact we cannot open the ASTView on OldSearchTests. Ask Frederic Fusier for exact steps to reproduce.
You can get it also with ConformTest. To reproduce it: 1) open the ASTView (Window->Show View->Other...->Java->ASTView), 2) open the file (ConformTest.java or OldSearchTests.java), 3) click on ASTView bar button 'Show AST of active editor' => you get the StackOverflow exception...
This is fixed and released in HEAD. AST view is still failing for OldSearchTests, because of the recursion done in the AST visitor, but it is fixed for ConformTests.
Verified for 3.0M9