shouting versus dotting

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Tue Oct 7 14:43:55 PDT 2008


Marcin Kuszczak wrote:
> Andrei Alexandrescu wrote:
> 
>> Aarti_pl wrote:
>>> I would be much more happy with implementation of my proposal:
>>> http://d.puremagic.com/issues/show_bug.cgi?id=1827
>>>
>>> I mean here especially syntax for "is expression" for templates.
>>>
>>> http://digitalmars.com/d/1.0/expression.html#IsExpression
>>>
>>> As it occurred on Tango conference in talk of Rafał Bocian (who lead the
>>> D course for students) syntax for "is expression" and specification
>>> (among few other things) is especially difficult for newbies in D.
>>>
>>> Unfortunately answer from Walter, why he didn't decide to change current
>>>  syntax was.... guess what? --- It doesn't look nice in code...
>>>
>>> Bad luck, said sad pirate .(
>>>
>>> BR
>>> Marcin Kuszczak
>>> (aarti_pl)
>> Your proposal should be reevaluated in wake of the conditional
>> templates, which Walter has implemented a couple of releases ago.
>>
>> Andrei
> 
> Yes, I am aware of that. They are just small part of the whole proposal, but
> currently implemented in such a way that it is not possible to use it in
> e.g. static asserts and aliases like it was proposed.
> 
> I still think that proposal is good (no one pointed out problems with it).
> It could be implemented as kind of compile time expression once, and then
> used in other places. It allows also more expressiveness and predictable
> syntax e.g. 
> void call(T : class)(T instance) {} 
> I hope that above mentioned issues with current design of IsExpression will
> be eventually fixed somehow, sometime...

I agree that pattern matching on type trees will have to make it into 
the language in one form or another. In fact, syntactically it is 
already there, but compiler bugs/limitations prevent it from happening. 
One thing with the notation you suggest is that it doesn't quite look 
like the rest of the language, and perhaps a few simple steps could be 
taken to make it more integrated.

> The strange think here is how minor issues (as most of community doesn't
> have problem with it) suddenly emerges from deeps and good ideas (which
> solve real problems) are sunken in the water... Well, I can give more
> examples if you want :-)

This is pointing at some being born into royalty while others' good work 
is under-compensated. Well in a way I'm glad you bring this up. One 
thing that has caused and is causing an amount of stir and occasional 
irritation is the perception that I came out of nowhere and captured 
Walter's attention effortlessly. The reality is that being neighbors 
with Walter was part of the mix, but the prosaic bulk of it is that 
Walter cared only because of my previous and ongoing 99% transpiration. 
For better or worse, this state of affairs makes it that whatever I say 
is perceived as much more intense, imposing, controversial, quirky, or 
arrogant, than it is, and therefore much more scrutinized and 
criticized. This reaction is entirely understandable, and I'm still 
thinking of ways to assuage it. In the meantime it's costing me time 
because I feel obligated to answer the many replies to my posts.

That being said, it is always great if you can bring to the fore more 
outstanding problems that you think have good solutions thought of by 
you or others. Just please consider the above when you compare and 
contrast them against the petty issue of "!()".


Andrei



More information about the Digitalmars-d mailing list