mirror of
https://github.com/github/semantic.git
synced 2024-12-25 07:55:12 +03:00
Add a function to convert These -> (,).
This commit is contained in:
parent
98a7c049b2
commit
f602dc90fe
@ -122,3 +122,4 @@ instance Show PrettyDiff where
|
||||
showDiff diff = toList . stripNewlines . Source.slice (getRange diff)
|
||||
stripNewlines = fmap (\ c -> if c == '\n' then ' ' else c)
|
||||
pad n string = showString (take n string) . showString (replicate (max 0 (n - length string)) ' ')
|
||||
toBoth them = (uncurry both . fromThese (const (repeat ' ')) (const (repeat ' ')) . runJoin $ showDiff <$> them) <*> sources
|
||||
|
Loading…
Reference in New Issue
Block a user