Copyright | (c) Eric Crockett 2011-2017 Chris Peikert 2011-2017 |
---|---|
License | GPL-2 |
Maintainer | ecrockett0@email.com |
Stability | experimental |
Portability | POSIX |
Safe Haskell | None |
Language | Haskell2010 |
Provides applicative-like functions for indexed vectors.
- data IZipVector m a
- iZipVector :: forall m a. Fact m => Vector a -> Maybe (IZipVector m a)
- unIZipVector :: IZipVector m a -> Vector a
- unzipIZV :: IZipVector m (a, b) -> (IZipVector m a, IZipVector m b)
Documentation
data IZipVector m a Source #
Indexed Zip Vector: a wrapper around a (boxed) Vector
that has
zip-py Applicative
behavior, analogous to
ZipList
for lists. The index m
enforces
proper lengths (and is necessary to implement pure
).
iZipVector :: forall m a. Fact m => Vector a -> Maybe (IZipVector m a) Source #
Smart constructor that checks whether length of input is right
(should be totient of m
).
unIZipVector :: IZipVector m a -> Vector a Source #
Deconstructor
unzipIZV :: IZipVector m (a, b) -> (IZipVector m a, IZipVector m b) Source #
Unzip an IZipVector.