Safe Haskell | None |
---|---|
Language | Haskell2010 |
Basement.Sized.UVect
Documentation
toUVect :: forall (n :: Nat) ty. (PrimType ty, KnownNat n, Countable ty n) => UArray ty -> Maybe (UVect n ty) Source #
replicate :: forall (n :: Nat) ty. (KnownNat n, Countable ty n, PrimType ty) => ty -> UVect n ty Source #
thaw :: forall (n :: Nat) prim ty. (KnownNat n, PrimMonad prim, PrimType ty) => UVect n ty -> prim (MUVect n ty (PrimState prim)) Source #
freeze :: forall prim ty (n :: Nat). (PrimMonad prim, PrimType ty, Countable ty n) => MUVect n ty (PrimState prim) -> prim (UVect n ty) Source #
map :: forall a b (n :: Nat). (PrimType a, PrimType b) => (a -> b) -> UVect n a -> UVect n b Source #
sub :: forall (i :: Nat) (j :: Nat) (n :: Nat) ty. ((i <=? n) ~ 'True, (j <=? n) ~ 'True, (i <=? j) ~ 'True, PrimType ty, KnownNat i, KnownNat j, Offsetable ty i, Offsetable ty j) => UVect n ty -> UVect (j - i) ty Source #
uncons :: forall (n :: Natural) ty. (CmpNat 0 n ~ 'LT, PrimType ty, KnownNat n, Offsetable ty n) => UVect n ty -> (ty, UVect (n - 1) ty) Source #
unsnoc :: forall (n :: Natural) ty. (CmpNat 0 n ~ 'LT, KnownNat n, PrimType ty, Offsetable ty n) => UVect n ty -> (UVect (n - 1) ty, ty) Source #
splitAt :: forall (i :: Natural) (n :: Natural) ty. (CmpNat i n ~ 'LT, PrimType ty, KnownNat i, Countable ty i) => UVect n ty -> (UVect i ty, UVect (n - i) ty) Source #