Idea for C++ Interop

Andrey Khropov andkhropov_nosp at m_mtu-net.ru
Sat Dec 23 01:04:24 PST 2006


Craig Black wrote:

> I've been thinking about how to provide interoperability between D and C++.
> One idea I had was to compile C++ to C.  I've never used such a compiler but
> I'm fairly sure that they exist.
> 
> Thoughts?

But what benefit can you obtain from this compared to just extern "C" ?

The problem is that C++ and D object models (and hence ABIs) aren't completely
compatible. So we have to stick to the lowest Common Denominator (C) or use
some component model like COM (it's already supported), CORBA, .NET CLR or JVM.

-- 
AKhropov



More information about the Digitalmars-d mailing list