1
1
mirror of https://github.com/github/semantic.git synced 2024-12-29 18:06:14 +03:00

Define sameCategory in terms of the toCategoryName computation.

This commit is contained in:
Rob Rix 2017-06-05 16:59:36 -04:00
parent d3edae8671
commit ff7234074d

View File

@ -146,7 +146,7 @@ dedupe = foldl' go []
find p x = List.break (p x)
exactMatch = (==) `on` getDeclaration
similarMatch a b = sameCategory a b && similarDeclaration a b
sameCategory = (==) `on` category
sameCategory = (==) `on` fmap toCategoryName . getDeclaration
similarDeclaration = (==) `on` fmap (toLower . declarationIdentifier) . getDeclaration
-- | Construct a 'JSONSummary' from an 'Entry'. Returns 'Nothing' for 'Unchanged' patches.