1
1
mirror of https://github.com/github/semantic.git synced 2024-12-22 06:11:49 +03:00

🔥 a bunch of unused instances.

This commit is contained in:
Rob Rix 2018-05-10 19:43:07 -04:00
parent 0b81b28213
commit 5f6fcba3bd

View File

@ -17,7 +17,7 @@ import Data.Semilattice.Lower
-- | A map of export names to an alias & address tuple.
newtype Exports location value = Exports { unExports :: Map.Map Name (Name, Maybe (Address location value)) }
deriving (Eq, Foldable, Functor, Generic1, Lower, Monoid, Ord, Semigroup, Show, Traversable)
deriving (Eq, Lower, Monoid, Ord, Semigroup, Show)
null :: Exports location value -> Bool
null = Map.null . unExports
@ -34,7 +34,3 @@ insert name alias address = Exports . Map.insert name (alias, address) . unExpor
-- TODO: Should we filter for duplicates here?
aliases :: Exports location value -> [(Name, Name)]
aliases = Map.toList . fmap fst . unExports
instance Eq location => Eq1 (Exports location) where liftEq = genericLiftEq
instance Ord location => Ord1 (Exports location) where liftCompare = genericLiftCompare
instance Show location => Show1 (Exports location) where liftShowsPrec = genericLiftShowsPrec