[Issue 4847] std.algorithm.topN documentation

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Mar 4 17:36:10 PST 2013


http://d.puremagic.com/issues/show_bug.cgi?id=4847



--- Comment #2 from bearophile_hugs at eml.cc 2013-03-04 17:36:08 PST ---
Thank you. But the second part of the request is not fulfilled:

>And I think it's better to add an usage example of topN(r1, r2).<


The documentation of the second overload of TopN says:


void topN(alias less = "a < b", SwapStrategy ss = SwapStrategy.unstable,
Range1, Range2)(Range1 r1, Range2 r2);
    Stores the smallest elements of the two ranges in the left-hand range.

    Example:



Do you want me to reopen this?

(By the way, I have found an unfiled problem, topN uses uniform(), but I think
the module doesn't import std.random).

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list