Tuple literal syntax

retard re at tard.com.invalid
Thu Oct 7 11:56:46 PDT 2010


Thu, 07 Oct 2010 13:48:31 -0500, Andrei Alexandrescu wrote:

> On 10/7/10 13:44 CDT, retard wrote:
>> Thu, 07 Oct 2010 19:12:45 +0200, Simen kjaeraas wrote:
>>
>>> retard<re at tard.com.invalid>  wrote:
>>>
>>>> If you don't have first class tuple constructors and define them with
>>>> a template, that's unfortunately not structural typing.
>>>
>>> Might I inquire as to why?
>>
>> I see these "tuples" defined with a template merely as structs in
>> disguise. They don't cover all the cases where built-in first class
>> tuples can be used.
> 
> Could you please take the time to put together a list of requirements?
> That would be great for either making Tuple better or for improving the
> language.

Sure, but I can't really promise to have to capacity to think about every 
possible case when we are discussing D. There are so many complex 
features! I think a more or less complete list can already be constructed 
from all past discussions here. The tuple issues come up every now and 
then.

FWIW, the library provided solution with syntactical support doesn't 
sound so bad now that I think about it. We just need to know, what we are 
trying to solve here. The bigger problems come up when overloading the 
same system with mixed value/type/alias tuples.


More information about the Digitalmars-d mailing list