range-set-list: Memory efficient sets with ranges of elements.

This is a package candidate release! Here you can preview how this package release will appear once published to the main package index (which can be accomplished via the 'maintain' link below). Please note that once a package has been published to the main package index it cannot be undone! Please consult the package uploading documentation for more information.

[maintain] [Publish]

Memory efficient sets with continuous ranges of discrete, bounded elements. List- and map-based implementations. Interface mimics Data.Set where possible.


[Skip to Readme]

Properties

Versions 0.0.1, 0.0.2, 0.0.3, 0.0.4, 0.0.5, 0.0.6, 0.0.7, 0.1.0.0, 0.1.1.0, 0.1.2.0, 0.1.2.1, 0.1.3, 0.1.3.1, 0.1.3.1
Change log CHANGELOG.md
Dependencies base (>=4.5 && <4.14), containers (>=0.5.3 && <0.7), deepseq (>=1.3.0.0 && <1.5), hashable (>=1.2.3.3 && <1.4), semigroups (>=0.16.2.2 && <0.20) [details]
License MIT
Author Oleg Grenrus <oleg.grenrus@iki.fi>
Maintainer Oleg Grenrus <oleg.grenrus@iki.fi>
Category Data
Home page https://github.com/phadej/range-set-list#readme
Bug tracker https://github.com/phadej/range-set-list/issues
Source repo head: git clone https://github.com/phadej/range-set-list
Uploaded by phadej at 2019-08-03T11:10:01Z

Modules

[Index] [Quick Jump]

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees


Readme for range-set-list-0.1.3.1

[back to package description]

range-set-list

Build Status Hackage Stackage LTS 2 Stackage LTS 3 Stackage Nightly

A few trivial implementations of range sets.

You can find the package (and its documentation) on hackage.

This module is intended to be imported qualified, to avoid name clashes with Prelude functions, e.g.,

import Data.RangeSet.List (RSet)
import qualified Data.RangeSet.List as RSet

This package contains two implementations of exactly the same interface, plus one specialization, all of which provide exactly the same behavior:

Compared to Data.Set, this module also imposes an Enum constraint for many functions. We must be able to identify consecutive elements to be able to glue and split ranges properly.

The implementation assumes that

x < succ x
pred x < x

and there aren't elements in between (not true for Float and Double). Also succ and pred are never called for largest or smallest value respectively.