go-diff icon indicating copy to clipboard operation
go-diff copied to clipboard

fix panic: runtime error: slice bounds out of range

Open iambus opened this issue 2 years ago • 4 comments

This PR should fix #127

The new code uses same implementation as the Java version: https://github.com/google/diff-match-patch/blob/62f2e689f498f9c92dbc588c58750addec9b1654/java/src/name/fraser/neil/plaintext/diff_match_patch.java#L545 https://github.com/google/diff-match-patch/blob/62f2e689f498f9c92dbc588c58750addec9b1654/java/src/name/fraser/neil/plaintext/diff_match_patch.java#L568

iambus avatar Dec 13 '21 09:12 iambus