From c0a9f2400f704c438b0cef4f4105e7bb6c3cbbff Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Mon, 22 Aug 2022 14:43:09 +0100 Subject: gentoo auto-resync : 22:08:2022 - 14:43:09 --- .../logict-state-0.1.0.5-monadfail-compat.patch | 64 ---------------------- 1 file changed, 64 deletions(-) delete mode 100644 dev-haskell/logict-state/files/logict-state-0.1.0.5-monadfail-compat.patch (limited to 'dev-haskell/logict-state/files') diff --git a/dev-haskell/logict-state/files/logict-state-0.1.0.5-monadfail-compat.patch b/dev-haskell/logict-state/files/logict-state-0.1.0.5-monadfail-compat.patch deleted file mode 100644 index 3da6f26e0dd4..000000000000 --- a/dev-haskell/logict-state/files/logict-state-0.1.0.5-monadfail-compat.patch +++ /dev/null @@ -1,64 +0,0 @@ -diff --git a/src/Control/Monad/LogicState.hs b/src/Control/Monad/LogicState.hs -index 93be8aa..613a77c 100644 ---- a/src/Control/Monad/LogicState.hs -+++ b/src/Control/Monad/LogicState.hs -@@ -1,4 +1,4 @@ --{-# LANGUAGE UndecidableInstances, Rank2Types, FlexibleInstances, FlexibleContexts, GADTs, ScopedTypeVariables, FunctionalDependencies #-} -+{-# LANGUAGE UndecidableInstances, Rank2Types, FlexibleInstances, FlexibleContexts, GADTs, ScopedTypeVariables, FunctionalDependencies, CPP #-} - - ------------------------------------------------------------------------- - -- | -@@ -39,6 +39,9 @@ import Control.Applicative - - import Control.Monad - import Control.Monad.Identity -+#if !MIN_VERSION_base(4,11,0) -+import qualified Control.Monad.Fail as Fail -+#endif - import Control.Monad.Trans - - import Control.Monad.State -@@ -83,7 +86,12 @@ instance Applicative (LogicStateT gs bs f) where - instance Monad (LogicStateT gs bs m) where - return a = LogicStateT ($ a) - m >>= f = LogicStateT $ \sk -> unLogicStateT m (\a -> unLogicStateT (f a) sk) -- fail _ = LogicStateT $ flip const -+#if !MIN_VERSION_base(4,11,0) -+ fail = Fail.fail -+#endif -+ -+instance MonadFail (LogicStateT gs bs m) where -+ fail _ = LogicStateT $ flip const - - instance Alternative (LogicStateT gs bs f) where - empty = LogicStateT $ flip const -diff --git a/src/Control/Monad/TransLogicState/Class.hs b/src/Control/Monad/TransLogicState/Class.hs -index 4fa61c4..267704a 100644 ---- a/src/Control/Monad/TransLogicState/Class.hs -+++ b/src/Control/Monad/TransLogicState/Class.hs -@@ -1,4 +1,4 @@ --{-# LANGUAGE ScopedTypeVariables #-} -+{-# LANGUAGE ScopedTypeVariables, CPP #-} - - module Control.Monad.TransLogicState.Class - ( TransLogicState(..) -@@ -15,12 +15,19 @@ import Control.Arrow - import Control.Monad.Identity - -- import Control.Monad.Trans - -+instance MonadFail Identity where -+ fail msg = runIdentity $ fail msg -+ - -- | Additions to MonadTrans specifically useful for LogicState - class {- MonadTrans t => -} TransLogicState s t where - ------------------------------------------------------------------------- - -- | Extracts the first result from a 't m' computation, - -- failing otherwise. -+#if !MIN_VERSION_base(4,13,0) - observeT :: (Monad m) => s -> t m a -> m a -+#else -+ observeT :: (MonadFail m) => s -> t m a -> m a -+#endif - observeT e m = fmap head $ observeManyT e 1 m - - ------------------------------------------------------------------------- -- cgit v1.2.3