mirror of
https://github.com/github/semantic.git
synced 2025-01-01 19:55:34 +03:00
Simplify leafWithRangesInSources.
This commit is contained in:
parent
b6044e788e
commit
7a71b76d99
@ -117,7 +117,7 @@ spec = parallel $ do
|
||||
|
||||
combineIntoLeaves (leaves, start) char = (leaves ++ [ Free $ Annotated (Info <$> (pure (Range start $ start + 1)) <*> mempty) (Leaf [ char ]) ], start + 1)
|
||||
|
||||
leafWithRangesInSources sources ranges = Free $ Annotated (Info <$> ranges <*> pure mempty) (Leaf $ toList (fst sources) ++ toList (snd sources))
|
||||
leafWithRangesInSources sources ranges = Free $ Annotated (Info <$> ranges <*> pure mempty) (Leaf $ runBothWith (++) (toList <$> sources))
|
||||
|
||||
patchWithBoth (Insert ()) = Insert . snd
|
||||
patchWithBoth (Delete ()) = Delete . fst
|
||||
|
Loading…
Reference in New Issue
Block a user