Bye bye, fast compilation times

jmh530 john.michael.hall at gmail.com
Wed Feb 7 01:47:19 UTC 2018


On Wednesday, 7 February 2018 at 01:20:04 UTC, H. S. Teoh wrote:
> So I'd like to propose that we do something similar to what we 
> did with template instantiations a couple of years ago: make it 
> so that unittests are only instantiated if the module they 
> occur in is being compiled, otherwise ignore them (even in the 
> face of -unittest).  This way, adding unittests to Phobos won't 
> cause unintentional slowdowns / unittest bloat across *all* D 
> projects that import the affected Phobos modules. (Seen from 
> this angle, it's a pretty hefty cost.)
>

Would it help to take the approach of mir, i.e. putting 
version(mir_test) before all the unittests?


More information about the Digitalmars-d mailing list