From 28246caa6c4acfa2709c57ca464e7fa1fd29ac3f Mon Sep 17 00:00:00 2001 From: Georgi Lyubenov Date: Thu, 18 Jun 2020 20:39:31 +0300 Subject: [PATCH] Fix warnings from upgrading to ghc 8.8.3 --- src/Polysemy/Embed.hs | 1 - src/Polysemy/Internal.hs | 1 - src/Polysemy/Internal/Union.hs | 3 +-- 3 files changed, 1 insertion(+), 4 deletions(-) diff --git a/src/Polysemy/Embed.hs b/src/Polysemy/Embed.hs index 2a3e315..38266d8 100644 --- a/src/Polysemy/Embed.hs +++ b/src/Polysemy/Embed.hs @@ -12,7 +12,6 @@ module Polysemy.Embed ) where import Polysemy -import Polysemy.Embed.Type (Embed (..)) ------------------------------------------------------------------------------ -- | Given a natural transform from @m1@ to @m2@ diff --git a/src/Polysemy/Internal.hs b/src/Polysemy/Internal.hs index 8fd5b1e..c7eafe7 100644 --- a/src/Polysemy/Internal.hs +++ b/src/Polysemy/Internal.hs @@ -40,7 +40,6 @@ module Polysemy.Internal import Control.Applicative import Control.Monad -import Control.Monad.Fail import Control.Monad.Fix import Control.Monad.IO.Class import Data.Functor.Identity diff --git a/src/Polysemy/Internal/Union.hs b/src/Polysemy/Internal/Union.hs index e7fa400..a383e3d 100644 --- a/src/Polysemy/Internal/Union.hs +++ b/src/Polysemy/Internal/Union.hs @@ -265,14 +265,13 @@ decomp (Union p a) = -- | Retrieve the last effect in a 'Union'. extract :: Union '[e] m a -> Weaving e m a extract (Union Here a) = a -extract (Union (There g) _) = case g of {} {-# INLINE extract #-} ------------------------------------------------------------------------------ -- | An empty union contains nothing, so this function is uncallable. absurdU :: Union '[] m a -> b -absurdU (Union pr _) = case pr of {} +absurdU = \case {} ------------------------------------------------------------------------------