Tuple literal syntax

bearophile bearophileHUGS at lycos.com
Sun Oct 10 07:36:57 PDT 2010


Simen kjaeraas:

> Perhaps it would be possible to augment struct static initializers for
> this purpose?
> 
> { int a; string b } foo( ) {
>      return { 1, "text" };
> }

What kind of tuple unpacking syntax do you suggest for this? (I think at the moment the unpacking syntax is more important than the literals one).

Bye,
bearophile


More information about the Digitalmars-d mailing list