On Tue, Apr 7, 2009 at 7:08 PM, bearophile <[email protected]> wrote:
> Stewart Gordon:
>> > - It can be a template, so it can be faster (confirmed. I have a sort that 
>> > is sometimes 3+ times faster).
>> What is there preventing a built-in sort being implemented in this way?
>
> Can you use templates with a statically compiled std lib?

The template would have to be in the "headers."  It wouldn't be
compiled into the library file itself.

The other problem with a templated sort is that while it's faster than
the current built-in sort, it also means there would be a different
template instantiation for every element type.  Not ideal.

Reply via email to