Moved these DataStructures from our old codebase, but made some changes
to fix persistent bugs like overlapping entries in the IntervalTree. The
interval tree will now return all values (including overlapping
intervals) from the main iterator.