1053
return (right.length > 0) ? right : left;
1054
} else if (this.ChangesOverlap(left[left.length - 1], right[0], mergedChangeArr)) {
1055
>
// Since we break the problem down recursively, it is possible that we
diff.ts
1056
>
// might recurse in the middle of a change thereby splitting it into
1057
>
// two changes. Here in the combining stage, we detect and fuse those
1058
>
// changes back together
1059
>
const result = new Array<DiffChange>(left.length + right.length - 1);
1060
>
MyArray.Copy(left, 0, result, 0, left.length - 1);
1061
>
result[left.length - 1] = mergedChangeArr[0];
1062
>
MyArray.Copy(right, 1, result, left.length, right.length - 1);
1063
>
1064
>
return result;
1065
} else {
1066
const result = new Array<DiffChange>(left.length + right.length);