-- Unfolding
-- ---------

-- | /O(n)/ Construct a vector by repeatedly applying the generator function
-- to a seed. The generator function yields 'Just' the next element and the
-- new seed or 'Nothing' if there are no more elements.
--
-- > unfoldr (\n -> if n == 0 then Nothing else Just (n,n-1)) 10
-- >  = <10,9,8,7,6,5,4,3,2,1>
unfoldr :: G.Vector (Vector k) (Rec (TaggedFunctor Identity) rs)
  => (c -> Maybe (Rec (TaggedFunctor Identity) rs, c)) -> c -> (Vector k) (Rec (TaggedFunctor Identity) rs)
unfoldr = G.unfoldr
unfoldr :: G.Vector (Vector k) (Rec (TaggedFunctor Identity) rs)
  => (c -> Maybe (Rec (TaggedFunctor Identity) rs, c)) -> c -> (Vector k) (Rec (TaggedFunctor Identity) rs)
unfoldr = G.unfoldr
unfoldr = G.unfoldr