Community
Participate
Working Groups
From bug 104997 java.lang.StringIndexOutOfBoundsException: String index out of range: 86 at java.lang.String.substring(String.java:1765) at org.eclipse.jdt.internal.ui.text.correction.AdvancedQuickAssistProcessor.getPickOutStringProposals(AdvancedQuickAssistProcessor.java:1563) at org.eclipse.jdt.internal.ui.text.correction.AdvancedQuickAssistProcessor.hasAssists(AdvancedQuickAssistProcessor.java:117) at org.eclipse.jdt.internal.ui.text.correction.JavaCorrectionProcessor$SafeHasAssist.safeRun(JavaCorrectionProcessor.java:359) at org.eclipse.jdt.internal.ui.text.correction.JavaCorrectionProcessor$SafeCorrectionProcessorAccess.run(JavaCorrectionProcessor.java:275) at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:1044) at org.eclipse.core.runtime.Platform.run(Platform.java:783) at org.eclipse.jdt.internal.ui.text.correction.JavaCorrectionProcessor$SafeCorrectionProcessorAccess.process(JavaCorrectionProcessor.java:271) at org.eclipse.jdt.internal.ui.text.correction.JavaCorrectionProcessor.hasAssists(JavaCorrectionProcessor.java:142) at org.eclipse.jdt.internal.ui.text.correction.QuickAssistLightBulbUpdater.calculateLightBulb(QuickAssistLightBulbUpdater.java:228) at org.eclipse.jdt.internal.ui.text.correction.QuickAssistLightBulbUpdater.doSelectionChanged(QuickAssistLightBulbUpdater.java:221) at org.eclipse.jdt.internal.ui.text.correction.QuickAssistLightBulbUpdater.access$0(QuickAssistLightBulbUpdater.java:204) at org.eclipse.jdt.internal.ui.text.correction.QuickAssistLightBulbUpdater$1.selectionChanged(QuickAssistLightBulbUpdater.java:128) at org.eclipse.jdt.internal.ui.viewsupport.SelectionListenerWithASTManager$PartListenerGroup.calculateASTandInform(SelectionListenerWithASTManager.java:173) at org.eclipse.jdt.internal.ui.viewsupport.SelectionListenerWithASTManager$3.run(SelectionListenerWithASTManager.java:142) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:76)
Hosam, do you have an code example where you got the problem with the 'pick out string' quick assist? Please reopen the bug if you do.
Excuse me, but what do you mean by the 'pick out string' quick assist?
The stack trace you had in your log points to a problem with the pick out string quick assist. An example would be String str= "Hello World"; - select 'World' - press CTRL + 1 - select 'Pick out selected part of String'. If you have any idea where you tried to do that, that would be great. It's of course possible that you never saw the proposal because of the bug...
The scenario seems familiar, although not quite the same. I have used a similar feature a lot. For example: String s = "SELECT * FROM MYTABLE"; I put the cursor before "FROM" and press Enter. The string is splitted. Sometimes I use it in another way, especially when copying text from outside. For example, I might copy a query, and the result would be as follows: String s = "SELECT * FROM MYTABLE WHERE CONDITION In such case I usually go to the end of the "SELECT *", and press Enter to get the '+' and '"' at the new line, and I keep doing so to put the rest of the query in concatenated strings. I hope this was helpful.
Comment 4 is a feature request. File a new bug against jdt.text for this.
Sorry, but I didn't mean to request a feature. It's already working for me! :)
As of now 'LATER' and 'REMIND' resolutions are no longer supported. Please reopen this bug if it is still valid for you.