mirror of
https://github.com/github/semantic.git
synced 2024-12-23 23:11:50 +03:00
Construct open or closed lines up front.
This commit is contained in:
parent
4b29ee9916
commit
f2c8d75879
@ -76,7 +76,7 @@ childRanges :: (Copointed c, Applicative f) => f Int -> c [f (Line (a, Range))]
|
||||
childRanges next child = unionLineRangesFrom <$> (rangeAt <$> next) <*> sequenceA (copoint child)
|
||||
|
||||
linesInRangeOfSource :: Range -> Source Char -> [Line Range]
|
||||
linesInRangeOfSource range source = pure <$> actualLineRanges range source
|
||||
linesInRangeOfSource range source = (if openRange source range then Line else Closed) . pure <$> actualLineRanges range source
|
||||
|
||||
-- | Wrap a list of child terms in a branch.
|
||||
makeBranchTerm :: (Info -> [inTerm] -> outTerm) -> Set.Set Category -> Int -> [(Maybe inTerm, Range)] -> (outTerm, Range)
|
||||
|
Loading…
Reference in New Issue
Block a user