www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 2919] New: Using .di files, does not always get all public imports

http://d.puremagic.com/issues/show_bug.cgi?id=2919

           Summary: Using .di files, does not always get all public imports
           Product: D
           Version: 1.042
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: benoit tionex.de


ATM i have no small test case for this.

In DWT2 there is:

java.lang.String:
alias char[] String;

java.lang.all:
public import java.lang.String;

org.eclipse.jface.viewers.ICellValidator:
import java.lang.all;
interface ICellValidator{
  public String isValid(Object o); // [1]
}

This compiles fine to a lib and the .di files are build also without problems.
Also application can compile with the generated headers. 
Now when building an application only the generated .di and the build libs
shall be used.
But in some scenarios the compiler complains at [1] (in the generated .di) that
'String' is not known. This happens also with other files that have interface
definitions.

To work around the problem, i can add the java.lang.String import to the module
with the interface. But that is obviously not a good solution, because it still
means that DMD is broken here.

I tried to play around with a few files, but was not able to trigger the bug.

So i file this bug report, so i can refer to it in my code where i put in those
work around imports.


-- 
May 02 2009