On Monday, 8 May 2017 at 14:47:36 UTC, Ethan Watson wrote:
I can answer #1, I know a few things there but that's more
something he should talk about as I don't know how public he's
made that knowledge.
Well, I know that DMD in particular made a trade off not to
collect garbage during the compilation to improve the speed,
so it is really interesting to look at their compiler sources
to find out what they did to make it compile so quickly.
On Monday, 8 May 2017 at 14:47:36 UTC, Ethan Watson wrote:
I also put forward to him a case with regards to compile time
execution and code generation. Say you've got a global variable
that you write to, and reading from that changes the kind of
code you will generate. Thus, your outputted code can be
entirely different according to whenever the compiler decides
to schedule that function for execution and compilation. His
response was, "Just don't do that."
That's essentially the philosophical difference there. Jonathan
wants a language with no restrictions, and leave it up to the
programmer to solve problems like the above themselves. Whether
you agree with that or not, well, that's an entirely different
matter.
At very least it is interesting to have this feature, I don't know
if I ever will need it in my code. For the game development use
case
it may be useful, for example to package all of the game assets at
compile time. I've seen similar thing being very popular in
different
Haxe-based game frameworks, though Haxe seems to be a bit more
restrictive in this regard.