DeRailed DSL (was Re: compile-time regex redux)

Bill Baxter dnewsgroup at billbaxter.com
Sat Feb 10 01:46:44 PST 2007


Kyle Furlong wrote:
> Andrei Alexandrescu (See Website For Email) wrote:

> I understand that you are a successful computer scientist. I accept that 
> you have had success with some books on the subject. I respect that you 
> currently research in the field. None of this allows you the freedoms 
> you have taken in the discussions you have been having.

Wow, this is sounding sillier and sillier.
It seems pretty clear to me that the answer is simply that Andrei 
doesn't really know enough about RoR give a concrete example of how 
better metaprogramming would be useful for DeRailed.  He pretty much 
said as much in the last mail.  But it would be good if he gave some 
more practical, concrete examples of places where it would help.

Note that what's going on here is *talk* about features that may or may 
not get into DMD any time soon.  In fact you could say this whole 
discussion has been about *preventing* features from getting introduced. 
  At least in an ad-hoc manner. This meat of this metaprogramming 
discussion started with Walter saying he was thinking of adding compile 
time regexps to the language.  Without any discussion about whether 
that's a good thing or not and what the ramifications are, then it's 
just going to happen, whether it's good for D or not.  So the question 
becomes what should D look like?  Rather than add hoc features, what do 
we really want D's metaprogramming to look like?

To me the discussion has all been about figuring out a clear picture of 
what things *should* look like in the future w.r.t. metaprogramming in 
order to convince Walter that throwing things in ad-hoc is not the way 
to go.  Or maybe to find out that what he's thinking of throwing in 
isn't so ad-hoc after all and actually makes for a nice evolutionary 
step towards where we want to go.

As for whether that would help DeRailed, I dunno.  Sounds like kris has 
a pretty clear idea that reflection would be much more useful to DeRailed.

As for whether DeRailed will help D, I also don't know.  I kinda wonder 
though, becuase if someone wants RoR, why wouldn't they just use RoR? 
Seems like it's a tough battle to unseat a champ like that.  I would 
think that D would have a better shot at dominating by providing a great 
solution to a niche which is currently underserved.  But that's just my 
opinion.  Also I don't do web development, so that may be another part 
of it.  But the description given of what Rails does so well, with all 
kinds of dynamic this and on-the-fly that, really sounds more like what 
a scripting language is good at than a static compile-time language.  I 
mean the dominant web languages are Perl, Python, Ruby, Php, and 
Javascript.  Not a compiled language in the bunch.  There's must be a 
reason for that.  Even Java is interpreted bytecode.

As for Andrei having Walter's ear.  I think Andrei has Walter's ear 
mostly because Andrei is interested in the same kinds of things that 
interest Walter.  I think everyone can tell by now that Walter pretty 
much works on solving the problems that interest him.   Right now (and 
pretty much ever since 'static if') the thing that seems to interest him 
most is metaprogramming.  Hopefully some day he'll get back to being 
interested in reflection.  But if he's really got the metaprogramming 
bug, then that may not be until after he's got D's compile time 
framework to a point where he feels it's "done".  But only Walter knows.



--bb



More information about the Digitalmars-d mailing list