Compile Imported Modules

Jonathan Marler via Digitalmars-d digitalmars-d at
Sat Aug 26 06:14:33 PDT 2017

On Saturday, 26 August 2017 at 06:31:11 UTC, user1234 wrote:
> On Friday, 25 August 2017 at 19:20:15 UTC, Jonathan Marler 
> wrote:
>> On Friday, 25 August 2017 at 13:15:35 UTC, Daniel N wrote:
>>> On Friday, 25 August 2017 at 13:03:11 UTC, Jonathan Marler 
>>> wrote:
>>>> I can do:
>>>> dmd -ci prog.d -Isomelib -Ianotherlib
>>> I love it, thanks for doing this!
>> Thanks, I think this is a really nice feature.  I've uploaded 
>> my build so that people can try it out here 
>> (
>> Just download and unzip, then run the addtopath.bat 
>> script in any shell you want to use this compiler in.  Thanks 
>> in advance to anyone who gives it a try and shares their 
>> thoughts.
> How does that mix with implicit imports (public imports located 
> in an explicit import) ?

All imported modules need to be compiled whether they were 
imported "explicitly" or "implicitly".  So both kinds work the 
same when it comes to this feature.

P.S. There are some cases where you can "get away" with not 
compiling a module, if it only contains declarations and 
templates for example.  In this case it kind of behaves like a 
header file in C/C++.

More information about the Digitalmars-d mailing list