Copyright | (c) Conal Elliott 2012 |
---|---|
License | BSD3 |
Maintainer | conal@conal.net |
Stability | experimental |
Safe Haskell | Safe |
Language | Haskell98 |
Finitely represented total maps. Represented by as a partial map and a default value. Has Applicative and Monad instances (unlike Data.Map).
Documentation
Total map
fromPartial :: a -> Map k a -> TMap k a Source
Create a total map from a default value and a partial map.
tabulate :: Eq k => v -> Set k -> (k -> v) -> TMap k v Source
Construct a total map, given a default value, a set of keys, and a
function to sample over that set. You might want to trim
the result.