An inconvenient truth

Steven Schveighoffer schveiguy at yahoo.com
Wed Oct 8 07:11:55 PDT 2008


"superdan" wrote
> Max Samukha Wrote:
>
>> On Wed, 08 Oct 2008 07:34:56 -0500, Andrei Alexandrescu
>> <SeeWebsiteForEmail at erdani.org> wrote:
>>
>> >Denis Koroskin wrote:
>> >> On Wed, 08 Oct 2008 16:21:02 +0400, Andrei Alexandrescu
>> >> <SeeWebsiteForEmail at erdani.org> wrote:
>> >>
>> >>> Walter discovered a showstopper for the curls.
>> >>>
>> >>> class A : B
>> >>> {
>> >>> }
>> >>>
>> >>>
>> >>> Andrei
>> >>
>> >> This is sad .(
>> >>
>> >> So, what are we left with now? Does everything stay as is or are we
>> >> still looking @ alternatives?
>> >
>> >I hope we will find a good notation after all. I hope people's patience
>> >hasn't worn thin. One thing that I noticed in the recent discussion was
>> >that quite a few people, even among supporters of the status quo,
>> >admitted that the !() syntax feels a bit odd at least in the beginning.
>> >
>> >Andrei
>>
>> I'm glad curls didn't get there. If I saw them in the beginning, my
>> first reaction would probably have been: "Why block delimiters for
>> template parameters? It's even odder than !(".
>
> how the heck. since like forever there's been three kinds of parens () [] 
> and {}. they pair n all. choosing one for template args is anyone's first 
> guess. but !( i bet you couldn't see comin' if it bit yer nose.
>
>> After staring for some time at templated code written by you and other
>> people, I feel like joining !( supporters. It doesn't shout at me any
>> louder than != or unary !. There needs to be a space after ! for it to
>> shout properly. Nesting is rare and alleviated by aliases.
>
> really!(how'd ya figure?) besides i often write code like
>
> sort!
>    ((string a, string b) { ... })
>    (array);
>
> pisses me off.

What about:

sort!(

or

sort
     !(

i.e. keep the ! with the (, it's not as bad.

-Steve 





More information about the Digitalmars-d mailing list