bitarray-0.0.1.1: Mutable and immutable bit arrays
Safe HaskellSafe-Inferred
LanguageHaskell98

Data.BitArray.ST

Description

Mutable one-dimensional packed bit arrays in the (strict) ST monad.

Synopsis

Documentation

getBitArrayBounds :: STBitArray s -> ST s (Int, Int) Source #

newBitArray :: (Int, Int) -> Bool -> ST s (STBitArray s) Source #

readBit :: STBitArray s -> Int -> ST s Bool Source #

writeBit :: STBitArray s -> Int -> Bool -> ST s () Source #

flipBit :: STBitArray s -> Int -> ST s Bool Source #

flips the bit and returns the old value

unsafeReadBit :: STBitArray s -> Int -> ST s Bool Source #

unsafeWriteBit :: STBitArray s -> Int -> Bool -> ST s () Source #

unsafeFlipBit :: STBitArray s -> Int -> ST s Bool Source #