proposal: lazy compilation model for compiling binaries

JS js.mdnq at gmail.com
Mon Jun 24 14:33:18 PDT 2013


On Monday, 24 June 2013 at 20:48:49 UTC, Jacob Carlborg wrote:
> On 2013-06-24 09:35, JS wrote:
>
>> It should be possible to "export"(or rather "share") types,
>> mixins, templates, generic unit tests, etc. (shared compile 
>> time
>> constructs would just be "copied" to a shared library as they
>> can't be compiled)
>
> These are compile time entities. I don't see why they need to 
> be in a library at all. Just having them in the 
> source/interface files is enough.


Having one file to share is better than many. It makes it easier 
to version, easier to maintain, and easier to distribute.

It is better than just zipping the collection of files, e.g. 
jar's, because it allows for better structural encoding but is 
effectively the same. Utilities can be used to extract/view 
specific information if needed.

The main benefit is versioning. One never has to worry about 
different parts of the library being out of sync because 
*everything* is compiled to one file. There is nothing to 
maintain except the source code.


More information about the Digitalmars-d mailing list