Implement TreeSeq.