D as a prototyping language (for C/C++ projects)

Rob T alanb at ucora.com
Wed Feb 27 11:51:03 PST 2013


On Wednesday, 27 February 2013 at 08:30:18 UTC, monarch_dodra 
wrote:
> On Tuesday, 26 February 2013 at 23:46:52 UTC, Rob T wrote:
>> Once full shared library support comes about, we'll be able to 
>> integrate D libs directly into existing C/C++ code. This 
>> allows for a safe migration path away from legacy C/C++ to D.
>>
>> --rt
>
> Funny story, I'm doing it the other way around.
>
> I got my program fully working in D, and am porting it to C.
>
> The basic idea is that I'm going to port it "chunk by chunk" to 
> C, while keeping my main in D. This allows me to "package" the 
> finished parts in C, but still work on the rest in D. It also 
> means the porting doesn't have to be done in its totality in a 
> single pass.

I understand why your are doing this, but it must be a ton of 
work, and has a lot of potential for introducing bugs that do not 
exist in the D code base.

Someone proposed that we compile D to JVM bytecode, but maybe we 
should have D compile to C or C++ source code instead, at least 
that can work fully unlike with JVM bytecode, and it would save 
you guys a lot of work

--rt


More information about the Digitalmars-d mailing list