Skip to content

Commit

Permalink
fixup! Improve delete performance
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisPenner committed Oct 4, 2020
1 parent dc40570 commit 2356887
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Data/TypeRepMap/Internal.hs
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ delete :: forall a (f :: KindOf a -> Type) . Typeable a => TypeRepMap f -> TypeR
delete m
| not (member @a m) = m
| size m == 1 = empty
| otherwise = fromSortedTriples . filter (\trip -> fst3 trip /= typeFp @a) . toSortedTriples $ m
| otherwise = fromSortedTriples . filter ((/= typeFp @a) . fst3) . toSortedTriples $ m
{-# INLINE delete #-}

{- |
Expand Down

0 comments on commit 2356887

Please sign in to comment.