DiffIterable (@NotNull Range range, @NotNull FairDiffIterable iterable, @NotNull CharSequence text1, @NotNull CharSequence text2, @NotNull LineOffsets lineOffsets1, @NotNull LineOffsets lineOffsets2, @NotNull BitSet ignored1, @NotNull BitSet ignored2) { List<Range> changedRanges = new ArrayList<>(); for (Range ch : iterable.iterateChanges()) { Range trimmedRange = TrimUtil.trimExpandRange(ch.start1, ch.start2, ch.end1, ch.end2, (index1, index2) -> areIgnoredEqualLines(range.start1 + index1, range.start2 + index2, text1, text2, lineOffsets1, lineOffsets2, ignored1, ignored2), index -> isIgnoredLine(range.start1 + index, lineOffsets1, ignored1), index -> isIgnoredLine(range.start2 + index, lineOffsets2, ignored2)); if (!trimmedRange.isEmpty()) changedRanges.add(trimmedRange); } return DiffIterableUtil.create(changedRanges, iterable.getLength1(), iterable.getLength2()); }