Safe Haskell | Safe-Inferred |
---|---|
Language | GHC2021 |
This module allows us to diff two Text
values.
Synopsis
- data TextDiff
- diffText :: Text -> Text -> FilePath -> Maybe TextDiff
- selectSpans :: [RealSrcSpan] -> TextDiff -> TextDiff
- printTextDiff :: TextDiff -> Term
Documentation
Result of diffing two Text
s.
:: Text | Text before |
-> Text | Text after |
-> FilePath | Path to use |
-> Maybe TextDiff | The resulting diff or |
Diff two texts and produce a TextDiff
.
selectSpans :: [RealSrcSpan] -> TextDiff -> TextDiff Source #
Select certain spans in the diff (line numbers are interpreted as belonging to the “before” state). Only selected spans will be printed.