strict-containers
Version 0.2 revision 0 uploaded by infinity0.
Package meta
- Synopsis
- Strict containers.
- Description
This package provides strict versions of some standard Haskell containers - including HashMap, IntMap, Map, Sequence, and Vector.
The reasoning is the same as that for our
strict
package - though some containers already define strict operations that force their inputs, the underlying data type is shared between the lazy and strict variants, i.e. by default lazy. In particular, instances are defined lazily on the common type, meaning that external utilities such aslens
,optics
, and deserialisation instances e.g. forbinary
andserialise
, all work lazily and there is not even the option to go strict.This package defines separate data types, to avoid these problems. Instances can then be defined on these fully-strict data types.
To be clear, the "strict" vs "lazy" discussion refers to the values of a map or the elements of a sequence. The standard variants of these data structures that can be lazy-or-strict are already always-strict in their keys (for maps) and lengths (for sequences) respectively. This is also why we don't define strict variants of sets here, since the standard variants are already strict in their elements.
Note: generally, instances for strict containers violate their respective laws in the presence of bottom (undefined, error, infinite-loop). In the absence of bottom, laws are preserved.
This library mirrors the API of the standard lazy-or-strict variants in
containers
andunordered-containers
, including methods and fundamental instances. It also contains instances forbinary
andindexed-traversable
. More instances are defined in other packages, e.g.strict-containers-lens
andstrict-containers-serialise
.The current version of this library has been autogenerated from:
containers v0.6.6
unordered-containers v0.2.19.1
vector vector-0.13.0.0
- Author
- n/a
- Bug reports
- n/a
- Category
- Data, Data Structures
- Copyright
- (c) 2021 by Ximin Luo
- Homepage
- https://github.com/haskellari/strict-containers
- Maintainer
- Ximin Luo <infinity0@pwned.gg>
- Package URL
- n/a
- Stability
- n/a