mirror of
https://github.com/dlang/phobos.git
synced 2025-04-29 14:40:30 +03:00
Remove std.conv import from quickSortImpl
This commit is contained in:
parent
42e2caa5c0
commit
d8e8f1f351
2 changed files with 8 additions and 7 deletions
|
@ -2164,12 +2164,12 @@ private void quickSortImpl(alias less, Range)(Range r, size_t depth)
|
|||
{
|
||||
import std.algorithm.comparison : min, max;
|
||||
import std.algorithm.mutation : swap, swapAt;
|
||||
import std.conv : to;
|
||||
|
||||
alias Elem = ElementType!(Range);
|
||||
enum size_t shortSortGetsBetter = max(32, 1024 / Elem.sizeof);
|
||||
enum int size = Elem.sizeof;
|
||||
enum size_t shortSortGetsBetter = max(32, 1024 / size);
|
||||
static assert(shortSortGetsBetter >= 1, Elem.stringof ~ " "
|
||||
~ to!string(Elem.sizeof));
|
||||
~ size.stringof);
|
||||
|
||||
// partition
|
||||
while (r.length > shortSortGetsBetter)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue