mirror of
https://github.com/github/semantic.git
synced 2025-01-04 21:47:07 +03:00
Document openRangePair.
This commit is contained in:
parent
f1b8e91723
commit
660cc1ad8b
@ -117,6 +117,7 @@ diffRanges (Pure patch) = fmap (characterRange . copoint) <$> unPatch patch
|
||||
openEither :: MaybeOpen a -> MaybeOpen b -> MaybeOpen (Either a b)
|
||||
openEither ifLeft ifRight which = either (fmap (const which) . ifLeft) (fmap (const which) . ifRight) which
|
||||
|
||||
-- | MaybeOpen test for (Range, a) pairs.
|
||||
openRangePair :: Source Char -> MaybeOpen (Range, a)
|
||||
openRangePair source pair = pair <$ openRange source (Prelude.fst pair)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user