Skip to content
This repository has been archived by the owner on Oct 12, 2022. It is now read-only.

Commit

Permalink
Merge pull request #970 from quickfur/adSort_1
Browse files Browse the repository at this point in the history
Don't use built-in array .sort in rt.util.container.treap
  • Loading branch information
WalterBright committed Sep 28, 2014
2 parents ec670e5 + f06ee9f commit 3dd38c0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/rt/util/container/treap.d
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ module rt.util.container.treap;

static import common = rt.util.container.common;
import rt.util.random;
import rt.qsort;

struct Treap(E)
{
Expand Down Expand Up @@ -277,7 +278,7 @@ initialLoop:
continue initialLoop;
}
}
data.sort;
_adSort(*cast(void[]*)&data, typeid(data[0]));
assert(treap == data);
assert(treap.valid());

Expand Down

0 comments on commit 3dd38c0

Please sign in to comment.