Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Ormolu.Diff.Text
Description
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.
Instances
Arguments
:: 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.