rrb-vector-0.2.1.0: Efficient RRB-Vectors
Safe HaskellSafe-Inferred
LanguageHaskell2010

Data.RRBVector.Internal.Debug

Description

This module contains some debug utilities. It should only be used for debugging/testing purposes.

Synopsis

Documentation

showTree :: Show a => Vector a -> String Source #

\(O(n)\). Show the underlying tree of a vector.

fromListUnbalanced :: [a] -> Vector a Source #

\(O(n)\). Create a new unbalanced vector from a list.

Note that it is not possbible to create an invalid Vector with this function.

pattern Empty :: Vector a Source #

pattern Root :: Int -> Shift -> Tree a -> Vector a Source #

data Tree a Source #

type Shift = Int Source #

pattern Balanced :: Array (Tree a) -> Tree a Source #

pattern Unbalanced :: Array (Tree a) -> PrimArray Int -> Tree a Source #

pattern Leaf :: Array a -> Tree a Source #