RBTree: Pure haskell Red-Black-Tree implemetation

[ bsd3, data-structures, library ] [ Propose Tags ] [ Report a vulnerability ]

This package implemets Red-Black tree data-structure.


[Skip to Readme]

Modules

[Index] [Quick Jump]

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

  • No Candidates
Versions [RSS] 0.0.1, 0.0.2, 0.0.3, 0.0.4, 0.0.5
Dependencies base (>3 && <5) [details]
License BSD-3-Clause
Copyright 2010-2011 Wu Xingbo (wuxb45@gmail.com)
Author Wu Xingbo
Maintainer Wu Xingbo
Category Data Structures
Home page git://github.com/wuxb45/Haskell-RBTree.git
Bug tracker mailto:wuxb45@gmail.com
Uploaded by XingboWu at 2011-06-09T15:31:02Z
Distributions NixOS:0.0.5
Reverse Dependencies 2 direct, 3 indirect [details]
Downloads 4988 total (11 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs available [build log]
Last success reported on 2024-03-23 [all 1 reports]

Readme for RBTree-0.0.5

[back to package description]
Pure haskell implementation from Wu Xingbo (wuxb45@gmail.com) 2011

WARNING:This Implementation mainly concerns about functionality. 
  After that I will improve the performence and efficiency.

to Build & Install for yourself:
shell> runhaskell Setup.lhs configure --user
shell> runhaskell Setup.lhs build
shell> runhaskell Setup.lhs install

on any problem, you may try this:
shell> runhaskell Setup.lhs register

for system, replace '--user' with '--ghc'

changelog (0.0.2):
add bangpatterns to some data field.
add ghc optimization flags to .cabal
be careful of memory usage. insert 10MiB Int values takes 3 seconds and 800MiB memory space.

changelog (0.0.3):
add function "searchFast".
rename 'remove*' functions to 'delete*'s.

changelog (0.0.4):
add functions for search min/max value.
add functions for search for a interval that the two values in the tree holds the given value
modified search functions can accept a 'compare' function like:
    (b -> a -> Ordering)
  search for an 'a' by first key of a (RBTree (a,b)) canbe done in such way:
> b :: Int
> b = 10
> t :: RBTree (Int,String)
> t = insertOrdList emptyRB [(1,"hello"), (2,"world")]
> result :: (Int,String)
> result = search (\k (k',_) -> k `compare` k') t 2
it returns "Just (2,"world")"

changelog (0.0.5):
add three operators for insert/delete/search.
updates the comments to co-op with haddock.
delete the RBTreeTest module. clean is better.