[Issue 2106] export class doesn't affect, what is exported

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed May 14 03:39:33 PDT 2008


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


torhu at yahoo.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |torhu at yahoo.com




------- Comment #1 from torhu at yahoo.com  2008-05-14 05:39 -------
(In reply to comment #0)
> the export modifier on class doesn't work as excepted.
> 
> export class A { export public void function(); }
> export class B : A { public void function2(); }
> 
> this code exports ONLY A.function(); ( i checked DLL with objdump )

I haven't tried getting classes inside DLLs to work myself.  But you should
probably provide a complete, compilable, minimal test case.

> 
> the following throws undefined error when linking:
> 
> B b = new B();
> A a = cast(A)b;

Do you need both lines to trigger the error, isn't the first one enough?


-- 



More information about the Digitalmars-d-bugs mailing list