| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Data.PrimitiveArray.Index.PhantomInt
Description
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 :: (Monad m, Num t2, Ord t2) => t -> t2 -> (t1, t2) -> m (Step (t1, t2) ((:.) t1 t2))
- streamDownMk :: Monad m => t -> t2 -> t1 -> m (t1, t2)
- streamDownStep :: (Monad m, Num t2, Ord t2) => 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 Ints.
Instances
| Vector Vector (PInt t p) Source | |
| MVector MVector (PInt t p) 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 | |
| ToJSON (PInt t p) Source | |
| FromJSON (PInt t p) Source | |
| Binary (PInt t p) Source | |
| Serialize (PInt t p) Source | |
| NFData (PInt t p) Source | |
| Hashable (PInt t p) Source | |
| Unbox (PInt t p) 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 s0 (PInt t0 p0) = MV_PInt (MVector s Int) Source | |
| type Rep (PInt t p) Source | |
| data Vector (PInt t0 p0) = V_PInt (Vector Int) Source |
streamUpMk :: Monad m => t2 -> t -> t1 -> m (t1, t2) Source
streamUpStep :: (Monad m, Num t2, Ord t2) => t -> t2 -> (t1, t2) -> m (Step (t1, t2) ((:.) t1 t2)) Source
streamDownMk :: Monad m => t -> t2 -> t1 -> m (t1, t2) Source