Community
Participate
Working Groups
2.0 Occasionally (2 or three times a week), Eclipse fails to insert a full import statement for a class which I've imported via contents assist. It inserts the 'import' keyword, and part of the class name. Here's an example: import org.eclipse.swt.layout.GridData; import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Button; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widg My import block was missing two imports: import org.eclipse.swt.widgets.Table; import org.eclipse.swt.widgets.TableColumn;
I think that this happens most frequently when I'm using content assist to generate anonymous inner classes.
Peter, can you provide a reproducable case (I know ....) ? Martin, please investigate if some comes to your mind that explains this behaviour.
When I do encounter the problem, it does seem to be repeatable. That is, if I undo a few steps and then repeat the insertion of the inner class, I get exactly the same truncated import statements. Unfortunately I haven't been able to come up with a simple repeatable test case which doesn't involve my whole workspace.
Just happened again - here's some more information: The problem occurs when I type something like new IFCBResourceRefreshListener[Ctrl+Space]([Ctrl+Space] It's important that I trigger the two code assists quickly, and that there be no code assist options to pick from (that is, only one suggestion, so no list appears). If I do it slowly, the error doesn't occur. It might also be relevant that IFCBResourceRefreshListener is inserted as the second last import, but I don't think so. If I start undoing and redoing, I can see that the following series of undoable actions occurred: 1) the import was correctly added in the right place 2) the inner class declaration was added 3) the imports were truncated
fixed > 20021030
Seems to be related to bug 26069 which is verified.