133 std::mt19937 generator;
134 std::uniform_int_distribution<int> distribution;
135 auto nextRandom = std::bind (distribution, generator);
141 for (
int i = 0; i < 100; ++i) {
160 for (
int i = 0; i < 100; ++i) {
176 for (
int i = 0; i < 100; ++i) {
204 if (safeTop->
start() !=
nullptr)
207 if (safeTop->
finish() !=
nullptr)
210 for (
int i = 0; i < 100; ++i) {
214 if (I.
i > 50 && I.
i < 10000000)
226 if (!safeTop->
start())
229 if (safeTop->
start()->data.i != 50)
235 if (safeTop->
finish()->data.i != 10000000)
244 if (aSplay.
start() !=
nullptr)
247 if (aSplay.
size() != 0)
252 if (aSplay.
start() ==
nullptr)
255 if (aSplay.
size() != 1)
260 if (aSplay.
start() !=
nullptr)
263 if (aSplay.
size() != 0)
static void VisitNode(intnode *const &)
static void VisitNodeRef(intnode const &)
static void VisitVoid(void *const &)
static void CheckNode(intnode const &)
SplayNode< V > const * start() const
void insert(Value const &, SPLAYCMP *compare)
SplayNode< V > const * finish() const
void destroy(SPLAYFREE *=DefaultFree)
static int compareintref(intnode const &a, intnode const &b)
static int compareint(intnode *const &a, intnode *const &b)
static void destintref(intnode &)
static int compareintvoid(void *const &a, void *const &n)
static void destint(intnode *&data)
static void destintvoid(void *&data)
void * xcalloc(size_t n, size_t sz)