Skip to content

Commit d22fc3a

Browse files
committed
comment
1 parent 116ee63 commit d22fc3a

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/support/intervals.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,9 @@ IntervalProcessor::filterOverlaps(std::vector<Interval>& intervals) {
4545
continue;
4646
}
4747

48-
// Former overlaps with candidate. Replace former if the weights are the same but the candidate ends earlier.
48+
// When two intervals overlap with the same weight, prefer to keep the
49+
// interval that ends sooner under the presumption that it will overlap with
50+
// fewer subsequent intervals.
4951
if (former.first.weight == candidate.first.weight &&
5052
former.first.end > candidate.first.end) {
5153
former = candidate;

0 commit comments

Comments
 (0)