Dst computes and returns the destination text.
(diffs []diffmatchpatch.Diff)
| 40 | |
| 41 | // Dst computes and returns the destination text. |
| 42 | func Dst(diffs []diffmatchpatch.Diff) string { |
| 43 | var text bytes.Buffer |
| 44 | for _, d := range diffs { |
| 45 | if d.Type != diffmatchpatch.DiffDelete { |
| 46 | text.WriteString(d.Text) |
| 47 | } |
| 48 | } |
| 49 | return text.String() |
| 50 | } |
| 51 | |
| 52 | // Src computes and returns the source text |
| 53 | func Src(diffs []diffmatchpatch.Diff) string { |