DIP11: Automatic downloading of libraries

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Tue Jun 14 16:27:04 PDT 2011


On 6/14/11 6:21 PM, Robert Clipsham wrote:
> On 14/06/2011 14:53, Andrei Alexandrescu wrote:
>> http://www.wikiservice.at/d/wiki.cgi?LanguageDevel/DIPs/DIP11
>>
>> Destroy.
>>
>>
>> Andrei
>
> More thoughts:
>
> * The compiler should be a compiler
> * Adding this makes the compiler a downloader and a compiler
> * If the compiler is a downloader, it should also be a builder and a
> package manager
> * Compiler now contains more C++ code that isn't to do with compiling.

All of these issues seem to be addressed by the emerging idea that dmd 
should cooperate with a companion binary that effects the downloading.

> The DIP mentions speed as a reason to integrate it into the compiler
> rather than have it separate. How about making dmd a bit more modular if
> you want the speed of having it in the compiler? Make a dmd library, the
> compiler can just be a main wrapper around it. This way:
>
> * The downloader/builder/package manager can be separate
> * The tool can be written in D, and still have the speed you want
> * It paves the way for other tools that could use dmd as a library
>
> The way I see this proposal is as a response to cpan/gem/pecl etc, a
> much needed package manager for D. I don't believe integrating it into
> the compiler is the right way to go, nor do I believe that a pragma is
> the right way to do it - I even refuse to use pragma(lib) as it doesn't
> work with incremental compilation - this wouldn't either.

The notion that the compiler communicates pragmas to its separated 
package manager during compilation - would that float your boat?


Andrei


More information about the Digitalmars-d mailing list