Safe Haskell | None |
---|---|
Language | Haskell2010 |
A linear 0-based int-index with a phantom type.
- newtype PInt t p = PInt {}
- pIntI :: Int -> PInt I p
- pIntO :: Int -> PInt O p
- pIntC :: Int -> PInt C p
- streamUpMk :: Monad m => t2 -> t -> t1 -> m (t1, t2)
- streamUpStep :: (Ord t2, Num t2, Monad m) => t -> t2 -> (t1, t2) -> m (Step (t1, t2) ((:.) t1 t2))
- streamDownMk :: Monad m => t -> t2 -> t1 -> m (t1, t2)
- streamDownStep :: (Ord t2, Num t2, Monad m) => t2 -> t -> (t1, t2) -> m (Step (t1, t2) ((:.) t1 t2))
Documentation
A PInt
behaves exactly like an Int
, but has an attached phantom
type p
. In particular, the Index
and IndexStream
instances are the
same as for raw Int
s.
Vector Vector (PInt t0 p0) Source # | |
MVector MVector (PInt t0 p0) Source # | |
Enum (PInt t p) Source # | |
Eq (PInt t p) Source # | |
Integral (PInt t p) Source # | |
(Data t, Data p) => Data (PInt t p) Source # | |
Num (PInt t p) Source # | |
Ord (PInt t p) Source # | |
Read (PInt t p) Source # | |
Real (PInt t p) Source # | |
Show (PInt t p) Source # | |
Ix (PInt t p) Source # | |
Generic (PInt t p) Source # | |
Hashable (PInt t p) Source # | |
FromJSON (PInt t p) Source # | |
ToJSON (PInt t p) Source # | |
Binary (PInt t p) Source # | |
Serialize (PInt t p) Source # | |
NFData (PInt t p) Source # | |
Unbox (PInt t0 p0) Source # | |
IndexStream z => IndexStream ((:.) z (PInt C p)) Source # | |
IndexStream z => IndexStream ((:.) z (PInt O p)) Source # | |
IndexStream z => IndexStream ((:.) z (PInt I p)) Source # | |
IndexStream (PInt C p) Source # | |
IndexStream (PInt O p) Source # | |
IndexStream (PInt I p) Source # | |
Index (PInt t p) Source # | |
data MVector s (PInt t0 p0) Source # | |
type Rep (PInt t p) Source # | |
data Vector (PInt t0 p0) Source # | |
streamUpMk :: Monad m => t2 -> t -> t1 -> m (t1, t2) Source #
streamUpStep :: (Ord t2, Num t2, Monad m) => t -> t2 -> (t1, t2) -> m (Step (t1, t2) ((:.) t1 t2)) Source #
streamDownMk :: Monad m => t -> t2 -> t1 -> m (t1, t2) Source #