Summary: | searchDeclarationsOf* incorrect | ||
---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Adam Kiezun <akiezun> |
Component: | Core | Assignee: | Jerome Lanneluc <jerome_lanneluc> |
Status: | RESOLVED FIXED | QA Contact: | |
Severity: | normal | ||
Priority: | P3 | ||
Version: | 2.0 | ||
Target Milestone: | 2.0 M1 | ||
Hardware: | PC | ||
OS: | Windows 2000 | ||
Whiteboard: |
Description
Adam Kiezun
2001-12-04 04:45:28 EST
i wrote searchDeclarationsOfReferencedTypes but i meant searchDeclarationsOfSentMessages this might be related so i'll paste it here: if you have sth like this in one cu: package p; class A { } class B extends A { private int f; private class P{} private void a(){} void m() { f++; P p= new P(); a(); } } and searchDeclarationsOfAccessedFields - you find none! same for the other 2 searchDeclarationsOf* methods (in their respective test cases) These are actually 2 different problems: 1. In the original test case, we did not restrict the search to the given method but to its compilation unit 2. In the second one, the declaration is found in a secondary type (thus not visible) Fixed the first problem by passing the given element to the DeclarationOf* pattern. Fixed the second problem by looking at the compilation unit of the given element to find the declaring type. |