Why is D unpopular?

Araq rumpf_a at web.de
Fri May 6 07:26:20 UTC 2022


On Thursday, 5 May 2022 at 23:06:26 UTC, Walter Bright wrote:
> On 5/3/2022 10:54 PM, Max Samukha wrote:
>> The important part is that Nemerle can execute functions at 
>> compile time - whether it's done via interpretation or 
>> compilation is not relevant to the argument. D could as well 
>> compile CTFE into native code or IL (as in newCTFE) from the 
>> start.
>
> That's pedantically true. But I can't seem to explain the 
> difference to you. D doesn't have a compiler in the runtime. 
> Having a compiler in the runtime means that you can dynamically 
> create code and compile it at runtime.
>
> It's a *fundamental* difference.
>
> If there is no difference (after all, all of them are Turing 
> machines, no difference at all!), and CTFE is popular and well 
> known, did
>
>     ZERO
>
> of the native compilers do it? Why didn't it appear on feature 
> wish lists? Why wasn't it in 
> C/C++/Pascal/Fortran/Module2/Ada/Algol compilers?
>

It was in the Nim(rod) compiler which is a Modula 3 derivate 
quite early in the project's lifetime, maybe as early as 2004, 
maybe later, I don't remember. And maybe D had it earlier. 
However:

1. I'm quite sure I didn't copy it from D. Because:
2. Nim actually **needs** it because otherwise its AST macro 
system simply cannot work.



More information about the Digitalmars-d mailing list