Community
Participate
Working Groups
Build ID: I20080617-2000 Steps To Reproduce: 1. Search for references in your workspace to an overridden "hashCode()" method More information: Trace: java.lang.NullPointerException at org.eclipse.jdt.internal.compiler.lookup.ReferenceBinding$3.compare(ReferenceBinding.java:58) at java.util.Arrays.mergeSort(Unknown Source) at java.util.Arrays.mergeSort(Unknown Source) at java.util.Arrays.mergeSort(Unknown Source) at java.util.Arrays.sort(Unknown Source) at java.util.Arrays.sort(Unknown Source) at org.eclipse.jdt.internal.compiler.lookup.ReferenceBinding.sortMethods(ReferenceBinding.java:160) at org.eclipse.jdt.internal.compiler.lookup.BinaryTypeBinding.availableMethods(BinaryTypeBinding.java:237) at org.eclipse.jdt.internal.core.search.matching.ClassFileMatchLocator.locateMatches(ClassFileMatchLocator.java:185) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.process(MatchLocator.java:1580) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.locateMatches(MatchLocator.java:1040) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.locateMatches(MatchLocator.java:1081) at org.eclipse.jdt.internal.core.search.matching.MatchLocator.locateMatches(MatchLocator.java:1198) at org.eclipse.jdt.internal.core.search.JavaSearchParticipant.locateMatches(JavaSearchParticipant.java:94) at org.eclipse.jdt.internal.core.search.BasicSearchEngine.findMatches(BasicSearchEngine.java:223) at org.eclipse.jdt.internal.core.search.BasicSearchEngine.search(BasicSearchEngine.java:506) at org.eclipse.jdt.core.search.SearchEngine.search(SearchEngine.java:551) at org.eclipse.jdt.internal.ui.search.JavaSearchQuery.run(JavaSearchQuery.java:144) at org.eclipse.search2.internal.ui.InternalSearchUI$InternalSearchJob.run(InternalSearchUI.java:94) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
This works for me. Do you have more details steps to reproduce?
Are you using a JRockit VM ?
I'm using the following JRE: java version "1.6.0" Java(TM) SE Runtime Environment (build pwi3260sr2-20080818_01(SR2)) IBM J9 VM (build 2.4, J2RE 1.6.0 IBM J9 2.4 Windows XP x86-32 jvmwi3260-20080816_22093 (JIT enabled, AOT enabled) J9VM - 20080816_022093_lHdSMr JIT - r9_20080721_1330ifx2 GC - 20080724_AA) JCL - 20080808_02 As for more detailed steps... sorry, that's literally all I did to run into this problem. I see the trace I pasted earlier every single time. Now, I tried this on a new workspace, checked out a few plug-ins, and ran the same scenario (Ctrl-Shift-G on overridden hashCode() method) and it worked fine. So maybe I've corrupted my workspace somehow? Anyway, I figured since you have a trace, you might be able to figure out how this problem might arise. Hope this helps.
Unfortunately, the trace doesn't tell enough to know what's wrong. So we would really need steps to reproduce. Sending us your workspace might help.
Closing as WORKSFORME. No steps provived. Reopen if you can help us understanding how you got it.
Verified for 3.6M4 using Build id: I20091209-0100
Verified.
*** Bug 263451 has been marked as a duplicate of this bug. ***
Got the same NPE with the steps from bug 293861 comment 62: - import the project https://anonsvn.jboss.org/repos/jbosstools/workspace/snjeza/jbide5036/jbide5036b.zip - select the test.Test.getName method and call Refactor>Rename
(In reply to comment #9) > Got the same NPE with the steps from bug 293861 comment 62: > > - import the project > https://anonsvn.jboss.org/repos/jbosstools/workspace/snjeza/jbide5036/jbide5036b.zip > - select the test.Test.getName method and call Refactor>Rename Sorry, you need to use https://anonsvn.jboss.org/repos/jbosstools/workspace/snjeza/jbide5036/jbide5036a.zip to reproduce it.
The exception looks the same as I observed in the bug 325418. The patch there does seem to help.
Satyam, please investigate.
The NPE mentioned here is the same reason why they are many spurious potential matches as mentioned in bug 325418. The fix for bug 325418 fixes even this. Hence marking this as duplicate. *** This bug has been marked as a duplicate of bug 325418 ***
.
Verified for 3.7M5 using build I20110124-1800.