Move Tree to its own module. Also, PartialOrd implementation was changed, so implement the new interface.