Bug 124295 - Indirectly referenced class file cannot be resolved
Summary: Indirectly referenced class file cannot be resolved
Status: RESOLVED DUPLICATE of bug 73957
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.2   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: PDE-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-01-18 10:03 EST by Gerd Wütherich CLA
Modified: 2006-01-22 18:12 EST (History)
2 users (show)

See Also:


Attachments
3 projects illustrating the problem (4.77 KB, application/octet-stream)
2006-01-18 10:04 EST, Gerd Wütherich CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gerd Wütherich CLA 2006-01-18 10:03:25 EST
We have 3 PDE bundles which reference each other: Project_A --> Project_B --> Project_C. (See attached Zip.)

Project_C defines and exports an exception (c.HiddenException). This is extended in Project_B (b.PublicException); Project_B only exports PublicException, since HiddenException should not be directly used by other bundles.

In Project_A we would like to reference b.PublicException, however the Eclipse compiler reports the error:
 "The type c.HiddenException cannot be resolved. It is indirectly referenced from required .class files"

In our view this should not happen since it breaks the bundle principle of encapsulation.
Comment 1 Gerd Wütherich CLA 2006-01-18 10:04:56 EST
Created attachment 33212 [details]
3 projects illustrating the problem

Importing these projects into the workspace illustrates the compile error in Project_A.
Comment 2 Gerd Wütherich CLA 2006-01-18 10:09:00 EST
If we change the definition of PublicException as follows, so that it doesn't extend c.HiddenException but rather just references it, then there is no compile problem with Project_A.

public class PublicException extends RuntimeException {
	private HiddenException hiddenException = null;
}


(This seems to imply that the problem is with class inheritance)
Comment 3 Jeff McAffer CLA 2006-01-21 20:53:53 EST
Isn't this the same as the other problem that PDE and JDT have been going back and forth on?
Comment 4 Wassim Melhem CLA 2006-01-22 18:12:59 EST
this is a dup of bug 73957.

That bug is not going back and forth.  We know what the problem is.  We just need to evaluate the risks/consequences of the suggested fix.

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