Gankro/collect-rs — pull request #19 by alexcrichton (2014-12-14 20:11:00+00:00)
Title: Add a splay tree implementation

I've had a [splay tree implementation][gh] externally, but it seems like this
may be a good new home for it!

[gh]: https://github.com/alexcrichton/splay-rs

This splay tree implementation is not quite of the quality one would expect of a
standard collection because it primarily doesn't implement iteration by
reference. Due to the self-modifying nature of lookups, I'm not 100% sure how to
safely implement iteration at this time, so only consuming iteration is
provided. Otherwise though I've tried to mirror the interface of HashMap as much
as possible in the implementation!

The implementation also leverages very little unsafe code, so it's not the most
efficient implementation by a long shot. Primarily the splay() method is
probably quite a bit larger than it needs to be!