-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Utilities for Control.Lens.Cons -- -- concise provides a handful of functions to extend what you can do with -- Control.Lens.Cons. @package concise @version 0.1.0.1 module Control.Lens.Cons.Extras -- | Convert one type with a Cons instance into the other. -- -- Rewrite rules are provided for efficient conversion between -- String and Text, [Word8] and -- ByteString, and lazy and strict Text and -- ByteString. Programs must be compiled with -O to use -- them. -- -- Although the type does not prove it, if (recons . recons) -- exists it should obey: -- --
--   recons . recons ≡ id
--   
-- -- The NOINLINE pragma is used to ensure that recons -- does not get inlined into function that are polymorphic in s1 -- or s2. Such functions should use the INLINE pragma -- to give rewrite rules the best chance of firing. recons :: (Cons s1 s1 a a, Cons s2 s2 a a, AsEmpty s2) => Getter s1 s2 -- |
--   unfoldr f = foldrOf (unfolded f) cons (_Empty # ())
--   
unfoldr :: (Cons s2 s2 a a, AsEmpty s2) => (s1 -> Maybe (a, s1)) -> s1 -> s2