| Summary: | binding do not fully consider working copies | ||
|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Adam Kiezun <akiezun> |
| Component: | Core | Assignee: | Jerome Lanneluc <jerome_lanneluc> |
| Status: | VERIFIED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | ||
| Version: | 2.1 | ||
| Target Milestone: | 3.0 M2 | ||
| Hardware: | PC | ||
| OS: | Windows 2000 | ||
| Whiteboard: | |||
Agreed. The unit where the resolve action is initiated should take precedence. Shared working copies are triggered in resolution slightly too early. Ignore my previous comment, I misunderstood the problem. Resolution of non local names only searches in existing units, as opposed to working copies (shared or not). What you are requesting instead is a mechanism for providing a set of working copies to override these existing units. This isn't currently planned. this is not good since it stops me from implementing important functionality i will try to come with a workaround and if i am not able to i will ask for reconsideration Reopening to consider with the work on closing the gap between cus and working copies. Added APIs to take a working copy owner (that now defines how working copies are shared) into argument: - AST.parseCompilationUnit(char[] source, String unitName, IJavaProject project, WorkingCopyOwner owner) - AST.parseCompilationUnit(IClassFile classFile, boolean resolveBindings, WorkingCopyOwner owner) - AST.parseCompilationUnit(ICompilationUnit unit, boolean resolveBindings, WorkingCopyOwner owner) These APIs do the resolution considering the working copies of the given owner first. Verified. |
(i asked on the mailing list but received no answer so i will treat it as a bug) I have a cu on disk - the cu looks like this: class A{} it has a corresponding shared working copy then i create 2 working copies: the first exists only in memory and has no corresponding cu on disk interface I{} and seconds one (this is _not_ the shared working copy - this one should shadow the shared working copy) class A implements I{} The problem is, that when I call resolveBinding() on A in the second working copy i get a binding with no superinterfaces.