For DLLs, what does export actually do?
    Ben Davis 
    entheh at cantab.net
       
    Sun Feb 10 06:11:26 PST 2013
    
    
  
On 10/02/2013 12:39, Benjamin Thaut wrote:
> Am 10.02.2013 13:36, schrieb Ben Davis:
>> With the def, I get lines like "DriverProc = _DriverProc at 20".
>> Without it, I get lines like "_DriverProc at 20 = _DriverProc at 20".
>
> Then you did hit this 3 year old bug:
> http://d.puremagic.com/issues/show_bug.cgi?id=3956
I don't think I did.
That bug applies to cases WITHOUT a .def file, and in that bug, the 
actual vs expected output is:
_DriverProc at mangledinsomeway (correct)
modMessage at mangledinsomeway (should be _modMessage at mangledinsomeway)
midMessage at mangledinsomeway (should be _midMessage at mangledinsomeway)
In my case, when I build without a .def file, I get:
_DriverProc at mangledinsomeway
_modMessage at mangledinsomeway
_midMessage at mangledinsomeway
not what I want, but correct as per the spec (I assume). Which would 
imply the bug was fixed at some point.
My example of "DriverProc =" (without the _) was WITH a .def file, AND 
is what I want - there is no bug as far as I'm aware.
For reference, when Andrej mentioned in earlier bug involving not having 
a .def, I thought of this one: 
http://www.digitalmars.com/d/archives/digitalmars/D/Windows_DLLs_and_TLS_177871.html
Hope it's clear now?
Ben :)
    
    
More information about the Digitalmars-d-learn
mailing list