Safe Haskell | None |
---|---|
Language | Haskell2010 |
Purebred.LazyVector
Description
Lazy vectors.
Documentation
A lazy vector. Linked list of chunks.
Instances
Functor V Source # | |
Foldable V Source # | |
Defined in Purebred.LazyVector Methods foldMap :: Monoid m => (a -> m) -> V a -> m foldr :: (a -> b -> b) -> b -> V a -> b foldr' :: (a -> b -> b) -> b -> V a -> b foldl :: (b -> a -> b) -> b -> V a -> b foldl' :: (b -> a -> b) -> b -> V a -> b foldr1 :: (a -> a -> a) -> V a -> a foldl1 :: (a -> a -> a) -> V a -> a | |
Traversable V Source # | |
Splittable V Source # | |
Eq a => Eq (V a) Source # | Θ(n) Concatenates chunks and checks equality. |
Ord a => Ord (V a) Source # | Θ(n) Concatenates chunks and compares. |
Show a => Show (V a) Source # | |
Semigroup (V a) Source # | |
Monoid (V a) Source # | |
Ixed (V a) Source # | |
Defined in Purebred.LazyVector | |
type Index (V a) Source # | |
Defined in Purebred.LazyVector type Index (V a) = Int | |
type IxValue (V a) Source # | |
Defined in Purebred.LazyVector type IxValue (V a) = a |
fromList :: Int -> [a] -> V a Source #
Lazily construct a V, slurping one chunk at a time
from the input list, with chunk size n
.
The minimum chunk size is 1. If the given value is less than 1, a chunk size of 1 is used.
fromChunks :: [Vector a] -> V a Source #