std.algorithm sort() and reverse() confusion
bearophile via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Mon Feb 2 08:54:37 PST 2015
Jonathan M Davis:
>> arr.reverse.map!sqrt
>
> Yes, but arguably, chaining calls in this case is bad,
We have discussed this some time... and I'd like reverse() to
return the original array (like the deprecated array .reverse
property). It's not a perfect design, but allowing UFCS chains is
quite important.
Bye,
bearophile
More information about the Digitalmars-d-learn
mailing list