Diff diffBuffers computes the diff between this buffer and the other buffer, reporting a sequence of operations that would convert this buffer (a) into the other buffer (b). Each operation is either an 'r' (replace), 'd' (delete), 'i' (insert) or 'e' (equal). Everything is line-based (0, offset).
(ob *Lines)
| 1831 | // the other buffer (b). Each operation is either an 'r' (replace), 'd' |
| 1832 | // (delete), 'i' (insert) or 'e' (equal). Everything is line-based (0, offset). |
| 1833 | func (ls *Lines) diffBuffers(ob *Lines) Diffs { |
| 1834 | astr := ls.strings(false) |
| 1835 | bstr := ob.strings(false) |
| 1836 | return DiffLines(astr, bstr) |
| 1837 | } |
| 1838 | |
| 1839 | // patchFromBuffer patches (edits) using content from other, |
| 1840 | // according to diff operations (e.g., as generated from DiffBufs). |
no test coverage detected