1
1
mirror of https://github.com/github/semantic.git synced 2024-11-24 08:54:07 +03:00

Remove the offset functions.

This commit is contained in:
Rob Rix 2015-12-22 17:12:08 -05:00
parent 08d03e933c
commit 1621dca3bc

View File

@ -94,8 +94,6 @@ spec = do
openTerm " \n" (Info (Range 0 2) mempty :< Leaf "") `shouldBe` Nothing
where
offsetInfo by (Info (Range start end) categories) = Info (Range (start + by) (end + by)) categories
offsetAnnotated by1 by2 (Annotated (left, right) syntax) = Annotated (offsetInfo by1 left, offsetInfo by2 right) syntax
isOpenBy f (Row a b) = Maybe.isJust (openLineBy f [ a ]) && Maybe.isJust (openLineBy f [ b ])
isClosedBy f (Row a@(Line _) b@(Line _)) = Maybe.isNothing (openLineBy f [ a ]) && Maybe.isNothing (openLineBy f [ b ])
isClosedBy _ (Row _ _) = False