Why is std.algorithm so complicated to use?

Jacob Carlborg doob at me.com
Tue Jul 10 12:04:02 PDT 2012


On 2012-07-10 19:55, Andrei Alexandrescu wrote:

> Clearly this and any documentation can be improved, but I'd say if it
> says "range" there there's no assumption "sorted range" there. I think
> the main thing that could be expressed better is "unique consecutive".

Fair enough.

>
> I think it would be onerous to mention for each algorithm, although
> clearly they all are generic, that they can handle ranges with any
> element type.
>
>> You see how stupid that is.
>
> That being what?

I was trying to point out that one cannot assume how a function behaves 
just by looking at one example. Specially not a template function.

-- 
/Jacob Carlborg




More information about the Digitalmars-d mailing list