Community
Participate
Working Groups
Build Eclipse 2.1.2 On the following setup, select package fragment 'p' located in project B and search for references. It will incorrectly report 2 matches: Project A +- package p +- A.java Project B prereqs A +- package p | +- B.java +- package c +- C.java package c; import p.A; import p.B; public class C { }
Problem comes from the fact we do not consider the focus element when matching inside import references. We likely have the same bug in qualified name or qualified type references.
Solved by checking for type existence in package fragment element (if provided). Addresses import ref, qualified type ref and qualified name ref; both source and binary. Need some regression tests, and need to also fix in 3.0 stream. Fixed
Added regression test JavaSearchMultipleProjectsTests.testPackageReference() in 2.1 maintenance stream.
Fix adapted and released in 3.0 stream
Fixed
Regression tests ported to 3.0 stream.
Verified for 3.0M6
Verified for 2.1.3 with build M200402251535.