Requires: T, T' two input trees with the same leaf set.