ral-0.2.2: Random access lists
Safe HaskellSafe
LanguageHaskell2010

Data.RAVec.NonEmpty

Description

Non-empty length-indexed random access list.

Synopsis

Random access list

newtype NERAVec (b :: BinP) a Source #

Non-empty random access list.

Constructors

NE (NERAVec' 'Z b a) 

Instances

Instances details
SBinPI b => Arbitrary1 (NERAVec b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

liftArbitrary :: Gen a -> Gen (NERAVec b a) #

liftShrink :: (a -> [a]) -> NERAVec b a -> [NERAVec b a] #

SBinPI b => Representable (NERAVec b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Associated Types

type Rep (NERAVec b) #

Methods

tabulate :: (Rep (NERAVec b) -> a) -> NERAVec b a #

index :: NERAVec b a -> Rep (NERAVec b) -> a #

Foldable (NERAVec b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

fold :: Monoid m => NERAVec b m -> m #

foldMap :: Monoid m => (a -> m) -> NERAVec b a -> m #

foldMap' :: Monoid m => (a -> m) -> NERAVec b a -> m #

foldr :: (a -> b0 -> b0) -> b0 -> NERAVec b a -> b0 #

foldr' :: (a -> b0 -> b0) -> b0 -> NERAVec b a -> b0 #

foldl :: (b0 -> a -> b0) -> b0 -> NERAVec b a -> b0 #

foldl' :: (b0 -> a -> b0) -> b0 -> NERAVec b a -> b0 #

foldr1 :: (a -> a -> a) -> NERAVec b a -> a #

foldl1 :: (a -> a -> a) -> NERAVec b a -> a #

toList :: NERAVec b a -> [a] #

null :: NERAVec b a -> Bool #

length :: NERAVec b a -> Int #

elem :: Eq a => a -> NERAVec b a -> Bool #

maximum :: Ord a => NERAVec b a -> a #

minimum :: Ord a => NERAVec b a -> a #

sum :: Num a => NERAVec b a -> a #

product :: Num a => NERAVec b a -> a #

Foldable1 (NERAVec b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

fold1 :: Semigroup m => NERAVec b m -> m #

foldMap1 :: Semigroup m => (a -> m) -> NERAVec b a -> m #

foldMap1' :: Semigroup m => (a -> m) -> NERAVec b a -> m #

toNonEmpty :: NERAVec b a -> NonEmpty a #

maximum :: Ord a => NERAVec b a -> a #

minimum :: Ord a => NERAVec b a -> a #

head :: NERAVec b a -> a #

last :: NERAVec b a -> a #

foldrMap1 :: (a -> b0) -> (a -> b0 -> b0) -> NERAVec b a -> b0 #

foldlMap1' :: (a -> b0) -> (b0 -> a -> b0) -> NERAVec b a -> b0 #

foldlMap1 :: (a -> b0) -> (b0 -> a -> b0) -> NERAVec b a -> b0 #

foldrMap1' :: (a -> b0) -> (a -> b0 -> b0) -> NERAVec b a -> b0 #

Traversable (NERAVec b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

traverse :: Applicative f => (a -> f b0) -> NERAVec b a -> f (NERAVec b b0) #

sequenceA :: Applicative f => NERAVec b (f a) -> f (NERAVec b a) #

mapM :: Monad m => (a -> m b0) -> NERAVec b a -> m (NERAVec b b0) #

sequence :: Monad m => NERAVec b (m a) -> m (NERAVec b a) #

SBinPI b => Applicative (NERAVec b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

pure :: a -> NERAVec b a #

(<*>) :: NERAVec b (a -> b0) -> NERAVec b a -> NERAVec b b0 #

liftA2 :: (a -> b0 -> c) -> NERAVec b a -> NERAVec b b0 -> NERAVec b c #

(*>) :: NERAVec b a -> NERAVec b b0 -> NERAVec b b0 #

(<*) :: NERAVec b a -> NERAVec b b0 -> NERAVec b a #

Functor (NERAVec b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

fmap :: (a -> b0) -> NERAVec b a -> NERAVec b b0 #

(<$) :: a -> NERAVec b b0 -> NERAVec b a #

SBinPI b => Distributive (NERAVec b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

distribute :: Functor f => f (NERAVec b a) -> NERAVec b (f a) #

collect :: Functor f => (a -> NERAVec b b0) -> f a -> NERAVec b (f b0) #

distributeM :: Monad m => m (NERAVec b a) -> NERAVec b (m a) #

collectM :: Monad m => (a -> NERAVec b b0) -> m a -> NERAVec b (m b0) #

Apply (NERAVec b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

(<.>) :: NERAVec b (a -> b0) -> NERAVec b a -> NERAVec b b0 #

(.>) :: NERAVec b a -> NERAVec b b0 -> NERAVec b b0 #

(<.) :: NERAVec b a -> NERAVec b b0 -> NERAVec b a #

liftF2 :: (a -> b0 -> c) -> NERAVec b a -> NERAVec b b0 -> NERAVec b c #

Traversable1 (NERAVec b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

traverse1 :: Apply f => (a -> f b0) -> NERAVec b a -> f (NERAVec b b0) #

sequence1 :: Apply f => NERAVec b (f b0) -> f (NERAVec b b0) #

FoldableWithIndex (PosP n) (NERAVec n) Source #

Since: 0.2

Instance details

Defined in Data.RAVec.NonEmpty

Methods

ifoldMap :: Monoid m => (PosP n -> a -> m) -> NERAVec n a -> m #

ifoldMap' :: Monoid m => (PosP n -> a -> m) -> NERAVec n a -> m #

ifoldr :: (PosP n -> a -> b -> b) -> b -> NERAVec n a -> b #

ifoldl :: (PosP n -> b -> a -> b) -> b -> NERAVec n a -> b #

ifoldr' :: (PosP n -> a -> b -> b) -> b -> NERAVec n a -> b #

ifoldl' :: (PosP n -> b -> a -> b) -> b -> NERAVec n a -> b #

FunctorWithIndex (PosP n) (NERAVec n) Source #

Since: 0.2

Instance details

Defined in Data.RAVec.NonEmpty

Methods

imap :: (PosP n -> a -> b) -> NERAVec n a -> NERAVec n b #

TraversableWithIndex (PosP n) (NERAVec n) Source #

Since: 0.2

Instance details

Defined in Data.RAVec.NonEmpty

Methods

itraverse :: Applicative f => (PosP n -> a -> f b) -> NERAVec n a -> f (NERAVec n b) #

(SBinPI b, Arbitrary a) => Arbitrary (NERAVec b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

arbitrary :: Gen (NERAVec b a) #

shrink :: NERAVec b a -> [NERAVec b a] #

CoArbitrary a => CoArbitrary (NERAVec b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

coarbitrary :: NERAVec b a -> Gen b0 -> Gen b0 #

(SBinPI b, Function a) => Function (NERAVec b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

function :: (NERAVec b a -> b0) -> NERAVec b a :-> b0 #

(Monoid a, SBinPI b) => Monoid (NERAVec b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

mempty :: NERAVec b a #

mappend :: NERAVec b a -> NERAVec b a -> NERAVec b a #

mconcat :: [NERAVec b a] -> NERAVec b a #

Semigroup a => Semigroup (NERAVec b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

(<>) :: NERAVec b a -> NERAVec b a -> NERAVec b a #

sconcat :: NonEmpty (NERAVec b a) -> NERAVec b a #

stimes :: Integral b0 => b0 -> NERAVec b a -> NERAVec b a #

Show a => Show (NERAVec b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

showsPrec :: Int -> NERAVec b a -> ShowS #

show :: NERAVec b a -> String #

showList :: [NERAVec b a] -> ShowS #

NFData a => NFData (NERAVec b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

rnf :: NERAVec b a -> () #

Eq a => Eq (NERAVec b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

(==) :: NERAVec b a -> NERAVec b a -> Bool #

(/=) :: NERAVec b a -> NERAVec b a -> Bool #

Ord a => Ord (NERAVec b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

compare :: NERAVec b a -> NERAVec b a -> Ordering #

(<) :: NERAVec b a -> NERAVec b a -> Bool #

(<=) :: NERAVec b a -> NERAVec b a -> Bool #

(>) :: NERAVec b a -> NERAVec b a -> Bool #

(>=) :: NERAVec b a -> NERAVec b a -> Bool #

max :: NERAVec b a -> NERAVec b a -> NERAVec b a #

min :: NERAVec b a -> NERAVec b a -> NERAVec b a #

Hashable a => Hashable (NERAVec b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

hashWithSalt :: Int -> NERAVec b a -> Int #

hash :: NERAVec b a -> Int #

type Rep (NERAVec b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

type Rep (NERAVec b) = PosP b

data NERAVec' (n :: Nat) (b :: BinP) a where Source #

Non-empty random access list, undelying representation.

Constructors

Last :: Tree n a -> NERAVec' n 'BE a 
Cons0 :: NERAVec' ('S n) b a -> NERAVec' n ('B0 b) a 
Cons1 :: Tree n a -> NERAVec' ('S n) b a -> NERAVec' n ('B1 b) a 

Instances

Instances details
(SBinPI b, SNatI n) => Arbitrary1 (NERAVec' n b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

liftArbitrary :: Gen a -> Gen (NERAVec' n b a) #

liftShrink :: (a -> [a]) -> NERAVec' n b a -> [NERAVec' n b a] #

(SBinPI b, SNatI n) => Representable (NERAVec' n b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Associated Types

type Rep (NERAVec' n b) #

Methods

tabulate :: (Rep (NERAVec' n b) -> a) -> NERAVec' n b a #

index :: NERAVec' n b a -> Rep (NERAVec' n b) -> a #

Foldable (NERAVec' n b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

fold :: Monoid m => NERAVec' n b m -> m #

foldMap :: Monoid m => (a -> m) -> NERAVec' n b a -> m #

foldMap' :: Monoid m => (a -> m) -> NERAVec' n b a -> m #

foldr :: (a -> b0 -> b0) -> b0 -> NERAVec' n b a -> b0 #

foldr' :: (a -> b0 -> b0) -> b0 -> NERAVec' n b a -> b0 #

foldl :: (b0 -> a -> b0) -> b0 -> NERAVec' n b a -> b0 #

foldl' :: (b0 -> a -> b0) -> b0 -> NERAVec' n b a -> b0 #

foldr1 :: (a -> a -> a) -> NERAVec' n b a -> a #

foldl1 :: (a -> a -> a) -> NERAVec' n b a -> a #

toList :: NERAVec' n b a -> [a] #

null :: NERAVec' n b a -> Bool #

length :: NERAVec' n b a -> Int #

elem :: Eq a => a -> NERAVec' n b a -> Bool #

maximum :: Ord a => NERAVec' n b a -> a #

minimum :: Ord a => NERAVec' n b a -> a #

sum :: Num a => NERAVec' n b a -> a #

product :: Num a => NERAVec' n b a -> a #

Foldable1 (NERAVec' n b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

fold1 :: Semigroup m => NERAVec' n b m -> m #

foldMap1 :: Semigroup m => (a -> m) -> NERAVec' n b a -> m #

foldMap1' :: Semigroup m => (a -> m) -> NERAVec' n b a -> m #

toNonEmpty :: NERAVec' n b a -> NonEmpty a #

maximum :: Ord a => NERAVec' n b a -> a #

minimum :: Ord a => NERAVec' n b a -> a #

head :: NERAVec' n b a -> a #

last :: NERAVec' n b a -> a #

foldrMap1 :: (a -> b0) -> (a -> b0 -> b0) -> NERAVec' n b a -> b0 #

foldlMap1' :: (a -> b0) -> (b0 -> a -> b0) -> NERAVec' n b a -> b0 #

foldlMap1 :: (a -> b0) -> (b0 -> a -> b0) -> NERAVec' n b a -> b0 #

foldrMap1' :: (a -> b0) -> (a -> b0 -> b0) -> NERAVec' n b a -> b0 #

Traversable (NERAVec' n b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

traverse :: Applicative f => (a -> f b0) -> NERAVec' n b a -> f (NERAVec' n b b0) #

sequenceA :: Applicative f => NERAVec' n b (f a) -> f (NERAVec' n b a) #

mapM :: Monad m => (a -> m b0) -> NERAVec' n b a -> m (NERAVec' n b b0) #

sequence :: Monad m => NERAVec' n b (m a) -> m (NERAVec' n b a) #

(SBinPI b, SNatI n) => Applicative (NERAVec' n b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

pure :: a -> NERAVec' n b a #

(<*>) :: NERAVec' n b (a -> b0) -> NERAVec' n b a -> NERAVec' n b b0 #

liftA2 :: (a -> b0 -> c) -> NERAVec' n b a -> NERAVec' n b b0 -> NERAVec' n b c #

(*>) :: NERAVec' n b a -> NERAVec' n b b0 -> NERAVec' n b b0 #

(<*) :: NERAVec' n b a -> NERAVec' n b b0 -> NERAVec' n b a #

Functor (NERAVec' n b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

fmap :: (a -> b0) -> NERAVec' n b a -> NERAVec' n b b0 #

(<$) :: a -> NERAVec' n b b0 -> NERAVec' n b a #

(SBinPI b, SNatI n) => Distributive (NERAVec' n b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

distribute :: Functor f => f (NERAVec' n b a) -> NERAVec' n b (f a) #

collect :: Functor f => (a -> NERAVec' n b b0) -> f a -> NERAVec' n b (f b0) #

distributeM :: Monad m => m (NERAVec' n b a) -> NERAVec' n b (m a) #

collectM :: Monad m => (a -> NERAVec' n b b0) -> m a -> NERAVec' n b (m b0) #

Apply (NERAVec' n b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

(<.>) :: NERAVec' n b (a -> b0) -> NERAVec' n b a -> NERAVec' n b b0 #

(.>) :: NERAVec' n b a -> NERAVec' n b b0 -> NERAVec' n b b0 #

(<.) :: NERAVec' n b a -> NERAVec' n b b0 -> NERAVec' n b a #

liftF2 :: (a -> b0 -> c) -> NERAVec' n b a -> NERAVec' n b b0 -> NERAVec' n b c #

Traversable1 (NERAVec' n b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

traverse1 :: Apply f => (a -> f b0) -> NERAVec' n b a -> f (NERAVec' n b b0) #

sequence1 :: Apply f => NERAVec' n b (f b0) -> f (NERAVec' n b b0) #

FoldableWithIndex (PosP' n m) (NERAVec' n m) Source #

Since: 0.2

Instance details

Defined in Data.RAVec.NonEmpty

Methods

ifoldMap :: Monoid m0 => (PosP' n m -> a -> m0) -> NERAVec' n m a -> m0 #

ifoldMap' :: Monoid m0 => (PosP' n m -> a -> m0) -> NERAVec' n m a -> m0 #

ifoldr :: (PosP' n m -> a -> b -> b) -> b -> NERAVec' n m a -> b #

ifoldl :: (PosP' n m -> b -> a -> b) -> b -> NERAVec' n m a -> b #

ifoldr' :: (PosP' n m -> a -> b -> b) -> b -> NERAVec' n m a -> b #

ifoldl' :: (PosP' n m -> b -> a -> b) -> b -> NERAVec' n m a -> b #

FunctorWithIndex (PosP' n m) (NERAVec' n m) Source #

Since: 0.2

Instance details

Defined in Data.RAVec.NonEmpty

Methods

imap :: (PosP' n m -> a -> b) -> NERAVec' n m a -> NERAVec' n m b #

TraversableWithIndex (PosP' n m) (NERAVec' n m) Source #

Since: 0.2

Instance details

Defined in Data.RAVec.NonEmpty

Methods

itraverse :: Applicative f => (PosP' n m -> a -> f b) -> NERAVec' n m a -> f (NERAVec' n m b) #

CoArbitrary a => CoArbitrary (NERAVec' n b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

coarbitrary :: NERAVec' n b a -> Gen b0 -> Gen b0 #

(SNatI n, SBinPI b, Function a) => Function (NERAVec' n b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

function :: (NERAVec' n b a -> b0) -> NERAVec' n b a :-> b0 #

(Monoid a, SBinPI b, SNatI n) => Monoid (NERAVec' n b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

mempty :: NERAVec' n b a #

mappend :: NERAVec' n b a -> NERAVec' n b a -> NERAVec' n b a #

mconcat :: [NERAVec' n b a] -> NERAVec' n b a #

Semigroup a => Semigroup (NERAVec' n b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

(<>) :: NERAVec' n b a -> NERAVec' n b a -> NERAVec' n b a #

sconcat :: NonEmpty (NERAVec' n b a) -> NERAVec' n b a #

stimes :: Integral b0 => b0 -> NERAVec' n b a -> NERAVec' n b a #

Show a => Show (NERAVec' n b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

showsPrec :: Int -> NERAVec' n b a -> ShowS #

show :: NERAVec' n b a -> String #

showList :: [NERAVec' n b a] -> ShowS #

NFData a => NFData (NERAVec' n b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

rnf :: NERAVec' n b a -> () #

Eq a => Eq (NERAVec' n b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

(==) :: NERAVec' n b a -> NERAVec' n b a -> Bool #

(/=) :: NERAVec' n b a -> NERAVec' n b a -> Bool #

Ord a => Ord (NERAVec' n b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

compare :: NERAVec' n b a -> NERAVec' n b a -> Ordering #

(<) :: NERAVec' n b a -> NERAVec' n b a -> Bool #

(<=) :: NERAVec' n b a -> NERAVec' n b a -> Bool #

(>) :: NERAVec' n b a -> NERAVec' n b a -> Bool #

(>=) :: NERAVec' n b a -> NERAVec' n b a -> Bool #

max :: NERAVec' n b a -> NERAVec' n b a -> NERAVec' n b a #

min :: NERAVec' n b a -> NERAVec' n b a -> NERAVec' n b a #

Hashable a => Hashable (NERAVec' n b a) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

Methods

hashWithSalt :: Int -> NERAVec' n b a -> Int #

hash :: NERAVec' n b a -> Int #

type Rep (NERAVec' n b) Source # 
Instance details

Defined in Data.RAVec.NonEmpty

type Rep (NERAVec' n b) = PosP' n b

Construction

singleton :: forall a. a -> NERAVec BinP1 a Source #

cons :: forall a b. a -> NERAVec b a -> NERAVec (Succ b) a Source #

cons for non-empty rals.

consTree :: Tree n a -> NERAVec' n b a -> NERAVec' n (Succ b) a Source #

withCons :: SBinPI b => a -> NERAVec b a -> (SBinPI (Succ b) => NERAVec (Succ b) a -> r) -> r Source #

withCons for non-empty rals.

withConsTree :: SBinP b -> Tree n a -> NERAVec' n b a -> (SBinPI (Succ b) => NERAVec' n (Succ b) a -> r) -> r Source #

Conversion

toList :: NERAVec b a -> [a] Source #

toList' :: NERAVec' n b a -> [a] Source #

reifyNonEmpty :: NonEmpty a -> (forall b. SBinPI b => NERAVec b a -> r) -> r Source #

reifyNonEmpty' :: forall a r. NonEmpty a -> (forall b. SBinPI b => NERAVec' 'Z b a -> r) -> r Source #

Indexing

(!) :: NERAVec b a -> PosP b -> a Source #

index' :: NERAVec' n b a -> PosP' n b -> a Source #

tabulate :: SBinPI b => (PosP b -> a) -> NERAVec b a Source #

tabulate' :: forall b n a. (SBinPI b, SNatI n) => (PosP' n b -> a) -> NERAVec' n b a Source #

head :: NERAVec b a -> a Source #

head' :: NERAVec' n b a -> a Source #

last :: NERAVec b a -> a Source #

last' :: NERAVec' n b a -> a Source #

Folds

foldMap :: Monoid m => (a -> m) -> NERAVec b a -> m Source #

foldMap' :: Monoid m => (a -> m) -> NERAVec' n b a -> m Source #

foldMap1 :: Semigroup m => (a -> m) -> NERAVec b a -> m Source #

foldMap1' :: Semigroup m => (a -> m) -> NERAVec' n b a -> m Source #

ifoldMap :: Monoid m => (PosP b -> a -> m) -> NERAVec b a -> m Source #

ifoldMap' :: Monoid m => (PosP' n b -> a -> m) -> NERAVec' n b a -> m Source #

ifoldMap1 :: Semigroup m => (PosP b -> a -> m) -> NERAVec b a -> m Source #

ifoldMap1' :: Semigroup m => (PosP' n b -> a -> m) -> NERAVec' n b a -> m Source #

foldr :: (a -> b -> b) -> b -> NERAVec m a -> b Source #

foldr' :: (a -> b -> b) -> b -> NERAVec' n m a -> b Source #

ifoldr :: (PosP m -> a -> b -> b) -> b -> NERAVec m a -> b Source #

ifoldr' :: (PosP' n m -> a -> b -> b) -> b -> NERAVec' n m a -> b Source #

foldr1Map :: (a -> b -> b) -> (a -> b) -> NERAVec m a -> b Source #

foldr1Map' :: (a -> b -> b) -> (a -> b) -> NERAVec' n m a -> b Source #

ifoldr1Map :: (PosP m -> a -> b -> b) -> (PosP m -> a -> b) -> NERAVec m a -> b Source #

ifoldr1Map' :: (PosP' n m -> a -> b -> b) -> (PosP' n m -> a -> b) -> NERAVec' n m a -> b Source #

Mapping

map :: (a -> b) -> NERAVec m a -> NERAVec m b Source #

map' :: (a -> b) -> NERAVec' n m a -> NERAVec' n m b Source #

imap :: (PosP m -> a -> b) -> NERAVec m a -> NERAVec m b Source #

imap' :: (PosP' n m -> a -> b) -> NERAVec' n m a -> NERAVec' n m b Source #

traverse :: Applicative f => (a -> f b) -> NERAVec m a -> f (NERAVec m b) Source #

traverse' :: Applicative f => (a -> f b) -> NERAVec' n m a -> f (NERAVec' n m b) Source #

itraverse :: Applicative f => (PosP m -> a -> f b) -> NERAVec m a -> f (NERAVec m b) Source #

itraverse' :: Applicative f => (PosP' n m -> a -> f b) -> NERAVec' n m a -> f (NERAVec' n m b) Source #

traverse1 :: Apply f => (a -> f b) -> NERAVec m a -> f (NERAVec m b) Source #

traverse1' :: Apply f => (a -> f b) -> NERAVec' n m a -> f (NERAVec' n m b) Source #

itraverse1 :: Apply f => (PosP m -> a -> f b) -> NERAVec m a -> f (NERAVec m b) Source #

itraverse1' :: Apply f => (PosP' n m -> a -> f b) -> NERAVec' n m a -> f (NERAVec' n m b) Source #

Zipping

zipWith :: (a -> b -> c) -> NERAVec m a -> NERAVec m b -> NERAVec m c Source #

zipWith' :: (a -> b -> c) -> NERAVec' n m a -> NERAVec' n m b -> NERAVec' n m c Source #

Zip two NERAVec's with a function.

izipWith :: (PosP m -> a -> b -> c) -> NERAVec m a -> NERAVec m b -> NERAVec m c Source #

izipWith' :: (PosP' n m -> a -> b -> c) -> NERAVec' n m a -> NERAVec' n m b -> NERAVec' n m c Source #

Zip two NERAVec's with a function which also takes PosP' index.

repeat :: SBinPI b => a -> NERAVec b a Source #

repeat' :: forall b n a. (SNatI n, SBinPI b) => a -> NERAVec' n b a Source #

Universe

universe :: forall b. SBinPI b => NERAVec b (PosP b) Source #

universe' :: forall n b. (SNatI n, SBinPI b) => NERAVec' n b (PosP' n b) Source #

QuickCheck

liftArbitrary' :: forall b n a. (SBinPI b, SNatI n) => Gen a -> Gen (NERAVec' n b a) Source #

liftShrink :: (a -> [a]) -> NERAVec b a -> [NERAVec b a] Source #

liftShrink' :: forall b n a. (a -> [a]) -> NERAVec' n b a -> [NERAVec' n b a] Source #