Is there any language that native-compiles faster than D?

kinke noone at nowhere.com
Thu Aug 20 21:49:16 UTC 2020


On Thursday, 20 August 2020 at 21:34:54 UTC, Per Nordlöw wrote:
> But for really large files that won't make that big of 
> difference.

Of course not, but your benchmark is as tiny as it gets. ;)

> I'll add the generation of the object.d file aswell.

For linking, a D main requires the _d_cmain template imported by 
object.d, so you'll have to make it extern(C) in that case.

> I'm aware of that. But I wanted to start somewhere and expand 
> from there.

I don't think languages can be compared like that. One would 
probably need a reasonably-sized non-contrived project and port 
it to each language, exploiting the language features, but then 
runtime and standard libraries would play a significant role as 
well (object.d kinda already does).
Another strong suit of D, its module system and compiling 
multiple modules at once, isn't reflected either.


More information about the Digitalmars-d mailing list