Methods like Intervals.expand should wrap the arrays they internally create (using FinalInterval.wrap) instead of copying them into a new FinalInterval.
Also It would be good if these methods would just return Interval instead of FinalInterval. But probably we cannot change that without breaking stuff. A possible way forward is deprecating Intervals and adding equivalent static methods to the Interval interface.
Methods like
Intervals.expand
should wrap the arrays they internally create (usingFinalInterval.wrap
) instead of copying them into a newFinalInterval
.Also It would be good if these methods would just return
Interval
instead ofFinalInterval
. But probably we cannot change that without breaking stuff. A possible way forward is deprecatingIntervals
and adding equivalent static methods to theInterval
interface.