deep-map: Deeply-nested, multiple key type maps.

[ bsd3, data, library, statistics ] [ Propose Tags ] [ Report a vulnerability ]

Modules

[Index] [Quick Jump]

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

  • No Candidates
Versions [RSS] 0.1.0.0, 0.1.1.0, 0.2.0, 0.2.0.1, 0.3.0, 0.3.1, 0.3.2 (info)
Change log CHANGELOG.md
Dependencies base (>=4.11 && <5), containers (>=0.5.11 && <0.8), indexed-traversable (>=0.1.2 && <0.2), witherable (>=0.5) [details]
License BSD-3-Clause
Copyright 2021-2024 Melanie Brown
Author Melanie Brown
Maintainer brown.m@pm.me
Category Data, Statistics
Home page https://github.com/mixphix/deep-map
Bug tracker https://github.com/mixphix/deep-map/issues
Uploaded by melaniebrown at 2024-11-20T17:05:37Z
Distributions NixOS:0.2.0.1
Downloads 371 total (56 in the last 30 days)
Rating 2.0 (votes: 1) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs available [build log]
Last success reported on 2024-11-20 [all 1 reports]

Readme for deep-map-0.3.2

[back to package description]

deep-map

ci Hackage license

A DeepMap is a map that has several layers of keys.

type DeepMap :: [Type] -> Type -> Type
data DeepMap ks v where
    Core :: v -> DeepMap '[] v
    Wrap :: Map k (DeepMap ks v) -> DeepMap (k ': ks) v

For a given (k ': ks) :: [Type], the type DeepMap (k ': ks) v is isomorphic to lists of the form [(k, k0, .., kn, v)] where ks = '[k0, ..., kn], but with better performance.