Another fun one: partialSort with two ranges

Andrei Alexandrescu via Digitalmars-d digitalmars-d at puremagic.com
Thu Dec 3 11:06:52 PST 2015


On 12/03/2015 11:09 AM, Vladimir Panteleev wrote:
> On Thursday, 3 December 2015 at 15:18:16 UTC, Andrei Alexandrescu wrote:
>> This should be pretty cool:
>>
>> https://issues.dlang.org/show_bug.cgi?id=15401
>>
>> Andrei
>
> Does chain not provide random access, thus allowing sorting a chain of
> two ranges?

Here the ranges must be distinct. It would be awkward to pass 
partialSort(chain(r1, r2), r1.length). -- Andrei



More information about the Digitalmars-d mailing list