Any takers for http://d.puremagic.com/issues/show_bug.cgi?id=9673?

Rainer Schuetze r.sagitario at gmx.de
Sun Mar 10 03:27:33 PDT 2013



On 10.03.2013 05:29, Andrei Alexandrescu wrote:
> I figure http://d.puremagic.com/issues/show_bug.cgi?id=9673 it's a great
> relatively confined project of good utility. We preapproved it, if
> anyone wants to snatch it please come forward.
>
> Also, any comments to the design are welcome.
>
>
> Thanks,
>
> Andrei

In my experience single file compilation of medium sized projects is 
unacceptably slow. Much slower than what you are used to by similar 
sized C++ projects. I think this is because without using di-files, a 
lot more code has to be analyzed for each compilation unit.

Another problem with single file compilation is that dependencies do not 
only cover changes to the declarations (as in C++) but also to the 
implementation, so the import chain can easily explode. A small change 
to the implementation of a function can trigger rebuilding a lot of 
other files.

The better option would be to pass all source files to update in one 
invocation of dmd, so it won't get slower than a full rebuild, but this 
has been plagued with linker errors in the past (undefined and duplicate 
symbols). If it works, it could identify independent group of files 
which you now separate into libraries.


More information about the Digitalmars-d mailing list