foreach

bearophile via Digitalmars-d digitalmars-d at puremagic.com
Thu Jun 12 09:59:32 PDT 2014


Nick Treleaven:

>there is also this usage:
>
> foreach (i, _; range){...}

I think this is a very uncommon usage. I think I have not used it 
so far.


> Potentially, there's also tuple unpacking syntax:
>
> auto (v, _) = myTuple;	// throw away second element

This is a very important usage. Worthing breaking D2 on.

Bye,
bearophile


More information about the Digitalmars-d mailing list