{-| Wrapper around 'Control.Monad.Logic'
-}

module Control.Monad.LogicState.Logic
  ( module Control.Monad.Logic
  , module Control.Monad.TransLogicState.Class
  )
  where

import           Control.Monad.Logic hiding (observeT, observeAllT, observeManyT, observe, observeAll, observeMany)
import qualified Control.Monad.Logic as CML
import           Control.Monad.Trans.Class (lift)

import           Control.Monad.TransLogicState.Class

instance TransLogicState () LogicT where
  observeT :: forall (m :: * -> *) a. MonadFail m => () -> LogicT m a -> m a
observeT ()
_ = forall (m :: * -> *) a. MonadFail m => LogicT m a -> m a
CML.observeT
  observeAllT :: forall (m :: * -> *) a. Monad m => () -> LogicT m a -> m [a]
observeAllT ()
_ = forall (m :: * -> *) a. Applicative m => LogicT m a -> m [a]
CML.observeAllT
  observeManyT :: forall (m :: * -> *) a. Monad m => () -> Int -> LogicT m a -> m [a]
observeManyT ()
_ = forall (m :: * -> *) a. Monad m => Int -> LogicT m a -> m [a]
CML.observeManyT
  liftWithState :: forall (m :: * -> *) a. Monad m => (() -> m (a, ())) -> LogicT m a
liftWithState () -> m (a, ())
m = forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift forall a b. (a -> b) -> a -> b
$ () -> m (a, ())
m () forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
>>= (forall (m :: * -> *) a. Monad m => a -> m a
return forall b c a. (b -> c) -> (a -> b) -> a -> c
. forall a b. (a, b) -> a
fst)