D and .lib files. C++/Other?

Damien Gibson via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sat Jul 1 20:53:49 PDT 2017


> If you're wanting to use the names (e.g. "ConsoleWrite") as is 
> on the C++ side them you need to declare them extern(C++) ( or 
> extern(C)) on the D side. if you were to run whatever the 
> equivalent of "nm my.dll | grep Console" on windows on the dll 
> then you'd see the two symbols with a different name (i.e. not 
> __imp_?ConsoleWrite at myclass@@SAXXZ).

Thanks for the reply.

Ive generated one using the extern(C) tag now, and checked it in 
Depends.exe(Dependency Walker) it now shows the Entry Point names 
as the correct names which is good news i really appreciate that. 
Its progress!

Though i still retain the errors when trying to run it with C++.


More information about the Digitalmars-d-learn mailing list