[ ArgumentList ] vs. @( ArgumentList )

Manu turkeyman at gmail.com
Tue Nov 6 12:13:23 PST 2012


On 6 November 2012 21:55, Faux Amis <faux at amis.com> wrote:

> On 06/11/2012 20:18, Walter Bright wrote:
>
>> For User Defined Attributes.
>>
>> In the north corner we have the current champeeeeon:
>>
>> -------
>> [ ArgumentList ]
>>
>> Pros:
>>      precedent with C#
>>      looks nice
>>
>> Cons:
>>      not so greppable
>>      parsing ambiguity with [array literal].func();
>>
>> ------
>> In the south corner, there's the chaaaaallenger:
>>
>> @( ArgumentList )
>>
>> Pros:
>>      looks like existing @attribute syntax
>>      no parsing problems
>>
>> Cons:
>>      not as nice looking
>> ------
>>
>> No hitting below the belt! Let the games begin!
>>
>
> With [] I expect array operations; can I slice it?
>

this is a really good point. they are a tuple, you can slice it, iterate
it...
further supports [] to my mind ;)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20121106/a4b0e67c/attachment.html>


More information about the Digitalmars-d mailing list