Copyright | (C) CSIRO 2017-2018 |
---|---|
License | BSD3 |
Maintainer | George Wilson <george.wilson@data61.csiro.au> |
Stability | experimental |
Portability | non-portable |
Safe Haskell | None |
Language | Haskell2010 |
Synopsis
- data NonEmptyVector a = NonEmptyVector a (Vector a)
- fromNel :: NonEmpty a -> NonEmptyVector a
- toNel :: NonEmptyVector a -> NonEmpty a
- toVector :: NonEmptyVector a -> Vector a
- headNev :: Lens' (NonEmptyVector a) a
- tailNev :: Lens' (NonEmptyVector a) (Vector a)
Documentation
data NonEmptyVector a Source #
A non-empty value of Vector
NonEmptyVector a (Vector a) |
Instances
fromNel :: NonEmpty a -> NonEmptyVector a Source #
Convert a NonEmpty
list to a NonEmptyVector
toNel :: NonEmptyVector a -> NonEmpty a Source #
Convert a NonEmptyVector
to a NonEmpty
list
toVector :: NonEmptyVector a -> Vector a Source #
Convert a NonEmptyVector
back to a Vector
headNev :: Lens' (NonEmptyVector a) a Source #
Get or set the head of a NonEmptyVector
tailNev :: Lens' (NonEmptyVector a) (Vector a) Source #
Get or set the head of a NonEmptyVector