This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 240544 - ArrayIndexOutOfBoundsException
Summary: ArrayIndexOutOfBoundsException
Status: RESOLVED DUPLICATE of bug 239542
Alias: None
Product: java
Classification: Unclassified
Component: Hints (show other bugs)
Version: 8.0
Hardware: All All
: P3 normal (vote)
Assignee: Svata Dedic
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-01-16 14:10 UTC by Martin Kanak
Modified: 2014-02-07 17:45 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter: 206619


Attachments
stacktrace (41 bytes, text/plain)
2014-01-16 14:10 UTC, Martin Kanak
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Kanak 2014-01-16 14:10:03 UTC
This issue was reported manually by kanakmar.
It already has 1 duplicates 


Build: NetBeans IDE 8.0 Beta (Build 201401141042)
VM: Java HotSpot(TM) 64-Bit Server VM, 25.0-b65, Java(TM) SE Runtime Environment, 1.8.0-ea-b123
OS: Windows 7

User Comments:
kanakmar: Exception appears after click on editor hint "Use Functional Operation"

Example code:

List<Instance> instance = loadInstances();
for(Instance i : instance){  //there is hint on this row and after click on it, the exception appears
...
}




Stacktrace: 
java.lang.ArrayIndexOutOfBoundsException
Comment 1 Martin Kanak 2014-01-16 14:10:04 UTC
Created attachment 144033 [details]
stacktrace
Comment 2 Marian Mirilovic 2014-02-05 08:09:52 UTC
...
java.lang.ArrayIndexOutOfBoundsException: -1
	at java.util.ArrayList.elementData(ArrayList.java:403)
	at java.util.ArrayList.get(ArrayList.java:416)
	at org.netbeans.modules.java.hints.jdk.mapreduce.Refactorer.isRefactorable(Refactorer.java:99)
	at org.netbeans.modules.java.hints.jdk.mapreduce.ForLoopToFunctionalHint$FixImpl.performRewrite(ForLoopToFunctionalHint.java:102)
	at org.netbeans.spi.java.hints.JavaFix$1.process(JavaFix.java:193)
...
Comment 3 Svata Dedic 2014-02-07 17:45:06 UTC

*** This bug has been marked as a duplicate of bug 239542 ***