Tuple assignment
Oren Tirosh via Digitalmars-d
digitalmars-d at puremagic.com
Sun May 10 01:47:06 PDT 2015
On Sunday, 10 May 2015 at 08:28:24 UTC, Russel Winder wrote:
> On Sun, 2015-05-10 at 08:14 +0000, Oren Tirosh via
> Digitalmars-d wrote:
>> On Saturday, 9 May 2015 at 17:16:58 UTC, Russel Winder wrote:
>> >
> […]
>> > TypeTuple!(current, next) = tuple(next , current
>> > +next);
>
> This works.
I did not mean imply that it doesn't, just that what I wrote is
not some proposed syntax for tuple assignment but something that
actually works now.
>
>> This works right now and is quite aesthetically pleasing:
>>
>> tuple(current, next) = tuple(next , current +next);
>
> This does not. At least the tests fail with this where they do
> not
> with the previous.
Works for me. If this is version or compiler dependent this
definitely needs investigation.
More information about the Digitalmars-d
mailing list