{-# LANGUAGE RankNTypes #-} -- | -- Copyright: (c) 2022 Bodigrim -- License: BSD3 module Data.List.Infinite.Internal ( Infinite (..), build, ) where -- | Type of infinite lists. data Infinite a = a :< Infinite a infixr 5 :< build :: forall a. (forall b. (a -> b -> b) -> b) -> Infinite a build :: forall a. (forall b. (a -> b -> b) -> b) -> Infinite a build forall b. (a -> b -> b) -> b g = forall b. (a -> b -> b) -> b g forall a. a -> Infinite a -> Infinite a (:<) {-# INLINE [1] build #-}