Community
Participate
Working Groups
20060410 Look at the following code with the (recovered) AST view: - in the AST View double click the block node of the initializer: > its source range does end in the middle of the second statement Add Olivier as CC as this might be related to the latest addition of incomplete ExpressionStatement package p1.sub1; import java.io.File; public class C2 { { new Thread(); File.pathSeparator; } }
The latest changes for bug 129330 were not released for the build you are using. I'll investigate.
I tried your test case with 0410 and with HEAD, and I never got wrong positions for the initializer. Can you reproduce all the time?
Oh, I used jdt.core HEAD.
Created attachment 38261 [details] screenshot ASTview
This has nothing to do with the latest changes in the recovered nodes. I can reproduce using 0410 where the changes are not included. David, The block doesn't have the same position than the initializer. The initializer's positions are ok, but the block is too short.
Created attachment 38785 [details] Proposed fix
Philippe - Do you want this fix for 3.2RC2 ?
+1 for 3.2RC2
Fix released and test added. ASTConverterTestAST3_2#test0645() Now, position of the block is the same as initializer.
Verified with I20060427-1600 for 3.2RC2