appendmap alternatives and similar packages
Based on the "Data Structures" category.
Alternatively, view appendmap alternatives based on common mentions on social networks and blogs.
-
Agda
Agda is a dependently typed programming language / interactive theorem prover. -
vinyl
Extensible Records for Haskell. Pull requests welcome! Come visit us on #vinyl on freenode. -
repa-eval
High performance, regular, shape polymorphic parallel arrays. -
repa-scalar
High performance, regular, shape polymorphic parallel arrays. -
repa-convert
High performance, regular, shape polymorphic parallel arrays. -
repa-array
High performance, regular, shape polymorphic parallel arrays. -
parameterized-utils
A set of utilities for using indexed types including containers, equality, and comparison. -
ethereum-client-haskell
A Haskell version of an Ethereum client -
psqueues
Priority Search Queues in three different flavors for Haskell -
type-level-sets
Type-level sets for Haskell (with value-level counterparts and various operations) -
justified-containers
Standard containers, with keys that carry type-level proofs of their own presence. -
bytestring-trie
An efficient finite map from (byte)strings to values. -
ixset-typed
More strongly typed variant of the ixset Haskell package -
knit
Ties the knot on data structures that reference each other by unique keys -
nonempty-containers
Efficient non-empty variants of containers data types, with full API -
eliminators
Dependently typed elimination functions using singletons -
claferIG
Support for reasoning on Clafer models by instantiation and counter example generation. -
igraph
Incomplete Haskell bindings to the igraph library (which is written in C) -
selections
Haskell Package for operating with selections over an underlying functor -
map-syntax
Syntax sugar and explicit semantics for statically defined maps
Updating dependencies is time-consuming.
Do you think we are missing an alternative of appendmap or a related project?
README
appendmap
A Data.Map
wrapper with a Semigroup
and Monoid
instances that delegate to
the individual keys.
import qualified Data.Map as Map
import Data.Map.Append
> one = AppendMap $ Map.fromList [(1, "hello"), (2, "goodbye")]
> two = AppendMap $ Map.fromList [(1, "world"), (3, "again")]
> unAppendMap (one <> two)
fromList [(1, "helloworld"), (2, "goodbye"), (3, "again")]
Motivation
Data.Map
has a Semigroup
instance that keeps the values from the first
argument in case of a key conflict:
import qualified Data.Map as Map
import Data.Map.Append
> Map.fromList [(1, "hello")] <> Map.fromList [(1, "goodbye")]
fromList [(1, "hello")]
A different instance has been suggested for a long time (1, 2), but this is a breaking change and hasn't happened yet (as of 2018-08).
Development
Source code is formatted with hindent
then stylish-haskell
.
Releasing
- Run
./bumpversion patch|minor|major
. This will create a new version and push it to the repository to be released.