Data.Vector.Storable

# Storable vectors

data Vector a

data MVector s a

class Storable a

# Accessors

## Length information

length

null

## Indexing

(!)

(!?)

head

last

unsafeIndex

unsafeHead

unsafeLast

## Monadic indexing

indexM

headM

lastM

unsafeIndexM

unsafeHeadM

unsafeLastM

## Extracting subvectors (slicing)

slice

init

tail

take

drop

splitAt

unsafeSlice

unsafeInit

unsafeTail

unsafeTake

unsafeDrop

# Construction

## Initialisation

empty

singleton

replicate

generate

iterateN

## Monadic initialisation

replicateM

generateM

create

## Unfolding

unfoldr

unfoldrN

constructN

constructrN

## Enumeration

enumFromN

enumFromStepN

enumFromTo

enumFromThenTo

## Concatenation

cons

snoc

(++)

concat

## Restricting memory usage

force

# Modifying vectors

## Bulk updates

(//)

update_

unsafeUpd

unsafeUpdate_

## Accumulations

accum

accumulate_

unsafeAccum

unsafeAccumulate_

## Permutations

reverse

backpermute

unsafeBackpermute

## Safe destructive updates

modify

# Elementwise operations

## Mapping

map

imap

concatMap

## Monadic mapping

mapM

mapM_

forM

forM_

## Zipping

zipWith

zipWith3

zipWith4

zipWith5

zipWith6

izipWith

izipWith3

izipWith4

izipWith5

izipWith6

## Monadic zipping

zipWithM

zipWithM_

# Working with predicates

## Filtering

filter

ifilter

filterM

takeWhile

dropWhile

## Partitioning

partition

unstablePartition

span

break

## Searching

elem

notElem

find

findIndex

findIndices

elemIndex

elemIndices

# Folding

foldl

foldl1

foldl'

foldl1'

foldr

foldr1

foldr'

foldr1'

ifoldl

ifoldl'

ifoldr

ifoldr'

## Specialised folds

all

any

and

or

sum

product

maximum

maximumBy

minimum

minimumBy

minIndex

minIndexBy

maxIndex

maxIndexBy

## Monadic folds

foldM

foldM'

fold1M

fold1M'

foldM_

foldM'_

fold1M_

fold1M'_

# Prefix sums (scans)

prescanl

prescanl'

postscanl

postscanl'

scanl

scanl'

scanl1

scanl1'

prescanr

prescanr'

postscanr

postscanr'

scanr

scanr'

scanr1

scanr1'

# Conversions

## Lists

toList

fromList

fromListN

## Other vector types

convert

unsafeCast

## Mutable vectors

freeze

thaw

copy

unsafeFreeze

unsafeThaw

unsafeCopy

# Raw pointers

unsafeFromForeignPtr

unsafeFromForeignPtr0

unsafeToForeignPtr

unsafeToForeignPtr0

unsafeWith