Copyright | (c) 2022 Composewell Technologies |
---|---|
License | BSD-3-Clause |
Maintainer | streamly@composewell.com |
Stability | experimental |
Portability | GHC |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Adds an orphan HashMap instance for the IsMap type class from streamly-core package. This is useful for various combinators that use a map type. We cannot define this in streamly-core as it adds several non-boot library dependencies on streamly-core.
Orphan instances
(Hashable k, Eq k) => IsMap (HashMap k) Source # | |
type Key (HashMap k) mapAlterF :: Functor g => (Maybe a -> g (Maybe a)) -> Key (HashMap k) -> HashMap k a -> g (HashMap k a) mapLookup :: Key (HashMap k) -> HashMap k a -> Maybe a mapInsert :: Key (HashMap k) -> a -> HashMap k a -> HashMap k a mapDelete :: Key (HashMap k) -> HashMap k a -> HashMap k a mapUnion :: HashMap k a -> HashMap k a -> HashMap k a mapNull :: HashMap k a -> Bool mapTraverseWithKey :: Applicative t => (Key (HashMap k) -> a -> t b) -> HashMap k a -> t (HashMap k b) |