From c8c195daf85dd1465f8bbbcbb8e932a0d77131bb Mon Sep 17 00:00:00 2001 From: Rob Rix Date: Mon, 11 Apr 2016 15:04:44 -0400 Subject: [PATCH] Rename getSize to size. --- src/Info.hs | 2 +- src/Parser.hs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Info.hs b/src/Info.hs index ad4a19908..98e16ce86 100644 --- a/src/Info.hs +++ b/src/Info.hs @@ -6,7 +6,7 @@ import Range -- | An annotation for a source file, including the source range and semantic -- | categories. -data Info = Info { characterRange :: !Range, categories :: !(Set Category), getSize :: !Integer } +data Info = Info { characterRange :: !Range, categories :: !(Set Category), size :: !Integer } deriving (Eq, Show) instance Categorizable Info where diff --git a/src/Parser.hs b/src/Parser.hs index 80463901c..e68f97f3f 100644 --- a/src/Parser.hs +++ b/src/Parser.hs @@ -40,7 +40,7 @@ isFixed = not . Set.null . Set.intersection fixedCategories -- | Given a function that maps production names to sets of categories, produce -- | a Constructor. termConstructor :: (String -> Set.Set Category) -> Constructor -termConstructor mapping source range name children = Info range categories (sum (getSize . copoint <$> children)) :< construct children +termConstructor mapping source range name children = Info range categories (sum (size . copoint <$> children)) :< construct children where categories = mapping name construct [] = Leaf . pack . toString $ slice range source