<div class="gmail_quote">On Fri, Jul 2, 2010 at 12:44 PM, Andrei Alexandrescu <span dir="ltr"><<a href="mailto:andrei@erdani.com">andrei@erdani.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Working around that would mess much of the elegance of std.sort, sigh. The nice thing is that sort reuses partition instead of writing a dedicated version of it (as I had in my implementation for a while). I was quite glad I'd pulled that off.<br>
<br>
Andrei<br></blockquote></div><br>Couldn't you just put in a second version of std.algorithm.partition that takes a second argument in addition to pred, similar to what you did for std.algorithm.count()?<br>