Andrei's Google Talk

Jonathan M Davis jmdavisprog at gmail.com
Fri Aug 6 17:43:55 PDT 2010


On Friday, August 06, 2010 16:35:57 Walter Bright wrote:
> Jonathan M Davis wrote:
> > Unfortunately, having to use dmc for C or C++ in order to link it with D
> > code in Windows would make D a non-starter for any project that couldn't
> > be in pure D where I work. Most of our stuff is cross-platform between
> > Linux and Windows, using gcc on Linux and Visual Studio on Windows, and
> > I don't think that there's any hope of getting anyone to switch to using
> > dmc. If D code could be linked with code generated by Microsoft's
> > compiler, then I'd have a much better chance of getting folks where I
> > work to use D. As it is, it would have to be for standalone projects
> > only, and most of our projects aren't standalone.
> 
> I hadn't realized that was a barrier.

It certainly wouldn't be for me personally for my own stuff (though I probably 
wouldn't be programming on Windows anyway), but the company I work for (and 
actually any that I've worked for which has used C++) has specificaly used Visual 
Studio with Microsoft's compiler and linker, and getting them to change that 
would take  _lot_ of convincing if not be outright impossible. So, if D code 
needs to link with the same linker as the C/C++ code in order for them to work 
together, then linking D with dmc instead of Microsoft's linker does become a 
serious barrier.

Unfortunately, in order to be able to use D where I work, I'd have to be able to 
link the D code with C/C++ code which has been built with Visual Studio and its 
compiler and linker. And, if I understand correctly, that means that the D code 
has to be linked with Microsoft's linker. If that's a misunderstanding on my 
part, then linking D with Microsoft's linker would be unnecessary, and dmc 
should do the job just fine (though only needing the one C/C++ linker over two 
would still be an improvement). But as I understand it, any C or C++ code which 
is going to be used with D code in Windows has to have been built with dmc.

- Jonathan M Davis


More information about the Digitalmars-d mailing list