mirror of
https://github.com/github/semantic.git
synced 2024-12-24 07:25:44 +03:00
Tidy up with fromMaybe.
This commit is contained in:
parent
83a88d0e32
commit
ad930bf047
@ -38,10 +38,7 @@ rws compare getLabel as bs
|
||||
then pure $! insert v
|
||||
else do
|
||||
put (Set.insert k mapped)
|
||||
case compare nearest v of
|
||||
Just y -> do
|
||||
pure y
|
||||
_ -> pure $! replace nearest v
|
||||
pure $! fromMaybe (replace nearest v) (compare nearest v)
|
||||
deleteRemaining diff mapped = diff <> (delete . snd <$> filter (not . (`Set.member` mapped) . fst) fas)
|
||||
|
||||
data Gram label = Gram { stem :: [Maybe label], base :: [Maybe label] }
|
||||
|
Loading…
Reference in New Issue
Block a user