Compilation strategy

Jonathan M Davis jmdavisProg at gmx.com
Sun Dec 16 17:10:33 PST 2012


On Sunday, December 16, 2012 16:57:31 Walter Bright wrote:
> I've done such (precompiled headers for C++), I've done .di files, and I've
> done Java bytecode. .di files are superior in nearly every way.

Given that .di don't work with inlining or CTFE, I'd consider them to be a 
very poor solution. You're seriously impairing yourself if you use them. It's 
pretty much BS that corporations insist on header files to hide implementation, 
since it really doesn't work, but if we're going to be forced to a have a 
solution which tries to hide implementation to make folks like that happy, we 
could at least have one that doesn't cripple the language like .di files do. It 
may not truly hide the implementation any better than .di files do, but at 
least it would allow us to still use the language properly.

I'm not expecting this problem to be fixed any time soon (we have far higher 
priorites), but I really do think that in the long run .di files should be 
deprecated in favor of a binary solution which doesn't stop things like 
inlining or CTFE from working.

- Jonathan M Davis


More information about the Digitalmars-d mailing list