Community
Participate
Working Groups
The current code assist template "fori" reads as: // Currently: for (int ${index} = 0; i < ${i:inner_expression(array)}.length; ${index}++) { ${cursor} } The hardcoded "i" in the loop condition should be parametrized like it is in pre-/post-loop statements with ${index} like this: // Should be: for (int ${index} = 0; ${index} < ${i:inner_expression(array)}.length; ${index}++) { ${cursor} } A similar bug exists in the "forr" template: // Currently: for (int ${index} = ${i:inner_expression(array)}.length - 1; i >= 0; ${index}--) { ${cursor} } // Should be: for (int ${index} = ${i:inner_expression(array)}.length - 1; ${index} >= 0; ${index}--) { ${cursor} }
Related: https://github.com/eclipse-jdt/eclipse.jdt.ui/pull/300 Seems like it's already fixed for the upcoming release?