PrimitiveArray-0.7.1.0: Efficient multidimensional arrays

Safe HaskellNone
LanguageHaskell2010

Data.PrimitiveArray.Index.Unit

Description

Unit indices admit a single element to be memoized. We can't use () because we want to attach phantom types.

Documentation

data Unit t Source #

Constructors

Unit 

Instances

Vector Vector (Unit t0) Source # 

Methods

basicUnsafeFreeze :: PrimMonad m => Mutable Vector (PrimState m) (Unit t0) -> m (Vector (Unit t0)) #

basicUnsafeThaw :: PrimMonad m => Vector (Unit t0) -> m (Mutable Vector (PrimState m) (Unit t0)) #

basicLength :: Vector (Unit t0) -> Int #

basicUnsafeSlice :: Int -> Int -> Vector (Unit t0) -> Vector (Unit t0) #

basicUnsafeIndexM :: Monad m => Vector (Unit t0) -> Int -> m (Unit t0) #

basicUnsafeCopy :: PrimMonad m => Mutable Vector (PrimState m) (Unit t0) -> Vector (Unit t0) -> m () #

elemseq :: Vector (Unit t0) -> Unit t0 -> b -> b #

MVector MVector (Unit t0) Source # 

Methods

basicLength :: MVector s (Unit t0) -> Int #

basicUnsafeSlice :: Int -> Int -> MVector s (Unit t0) -> MVector s (Unit t0) #

basicOverlaps :: MVector s (Unit t0) -> MVector s (Unit t0) -> Bool #

basicUnsafeNew :: PrimMonad m => Int -> m (MVector (PrimState m) (Unit t0)) #

basicInitialize :: PrimMonad m => MVector (PrimState m) (Unit t0) -> m () #

basicUnsafeReplicate :: PrimMonad m => Int -> Unit t0 -> m (MVector (PrimState m) (Unit t0)) #

basicUnsafeRead :: PrimMonad m => MVector (PrimState m) (Unit t0) -> Int -> m (Unit t0) #

basicUnsafeWrite :: PrimMonad m => MVector (PrimState m) (Unit t0) -> Int -> Unit t0 -> m () #

basicClear :: PrimMonad m => MVector (PrimState m) (Unit t0) -> m () #

basicSet :: PrimMonad m => MVector (PrimState m) (Unit t0) -> Unit t0 -> m () #

basicUnsafeCopy :: PrimMonad m => MVector (PrimState m) (Unit t0) -> MVector (PrimState m) (Unit t0) -> m () #

basicUnsafeMove :: PrimMonad m => MVector (PrimState m) (Unit t0) -> MVector (PrimState m) (Unit t0) -> m () #

basicUnsafeGrow :: PrimMonad m => MVector (PrimState m) (Unit t0) -> Int -> m (MVector (PrimState m) (Unit t0)) #

Eq (Unit t) Source # 

Methods

(==) :: Unit t -> Unit t -> Bool #

(/=) :: Unit t -> Unit t -> Bool #

Ord (Unit t) Source # 

Methods

compare :: Unit t -> Unit t -> Ordering #

(<) :: Unit t -> Unit t -> Bool #

(<=) :: Unit t -> Unit t -> Bool #

(>) :: Unit t -> Unit t -> Bool #

(>=) :: Unit t -> Unit t -> Bool #

max :: Unit t -> Unit t -> Unit t #

min :: Unit t -> Unit t -> Unit t #

Read (Unit t) Source # 
Show (Unit t) Source # 

Methods

showsPrec :: Int -> Unit t -> ShowS #

show :: Unit t -> String #

showList :: [Unit t] -> ShowS #

Generic (Unit t) Source # 

Associated Types

type Rep (Unit t) :: * -> * #

Methods

from :: Unit t -> Rep (Unit t) x #

to :: Rep (Unit t) x -> Unit t #

Arbitrary (Unit t) Source # 

Methods

arbitrary :: Gen (Unit t) #

shrink :: Unit t -> [Unit t] #

Hashable (Unit t) Source # 

Methods

hashWithSalt :: Int -> Unit t -> Int #

hash :: Unit t -> Int #

FromJSON (Unit t) Source # 
ToJSON (Unit t) Source # 
Binary (Unit t) Source # 

Methods

put :: Unit t -> Put #

get :: Get (Unit t) #

putList :: [Unit t] -> Put #

Serialize (Unit t) Source # 

Methods

put :: Putter (Unit t) #

get :: Get (Unit t) #

NFData (Unit t) Source # 

Methods

rnf :: Unit t -> () #

Unbox (Unit t0) Source # 
IndexStream ((:.) Z (Unit t)) => IndexStream (Unit t) Source # 

Methods

streamUp :: Monad m => Unit t -> Unit t -> Stream m (Unit t) Source #

streamDown :: Monad m => Unit t -> Unit t -> Stream m (Unit t) Source #

Index (Unit t) Source # 
IndexStream z => IndexStream ((:.) z (Unit t)) Source # 

Methods

streamUp :: Monad m => (z :. Unit t) -> (z :. Unit t) -> Stream m (z :. Unit t) Source #

streamDown :: Monad m => (z :. Unit t) -> (z :. Unit t) -> Stream m (z :. Unit t) Source #

data MVector s (Unit t0) Source # 
data MVector s (Unit t0) = MV_Unit (MVector s ())
type Rep (Unit t) Source # 
type Rep (Unit t) = D1 (MetaData "Unit" "Data.PrimitiveArray.Index.Unit" "PrimitiveArray-0.7.1.0-B4A9oZDNxHW51HjshiHgYe" False) (C1 (MetaCons "Unit" PrefixI False) U1)
data Vector (Unit t0) Source # 
data Vector (Unit t0) = V_Unit (Vector ())