From 3c8cb7f43c89e9a2b754adc5e639985f0b95b1f1 Mon Sep 17 00:00:00 2001 From: Herbert Valerio Riedel Date: Thu, 31 Dec 2015 16:42:38 +0100 Subject: Remove some redundant definitions/constraints Starting with GHC 7.10 and base-4.8, `Monad` implies `Applicative`, which allows to simplify some definitions to exploit the superclass relationship. This a first refactoring to that end. --- compiler/utils/Maybes.hs | 2 -- 1 file changed, 2 deletions(-) (limited to 'compiler/utils/Maybes.hs') diff --git a/compiler/utils/Maybes.hs b/compiler/utils/Maybes.hs index ac5107029b..83dc9b6864 100644 --- a/compiler/utils/Maybes.hs +++ b/compiler/utils/Maybes.hs @@ -17,7 +17,6 @@ module Maybes ( MaybeT(..), liftMaybeT ) where -import Control.Applicative as A import Control.Monad import Control.Monad.Trans.Maybe import Data.Maybe @@ -84,7 +83,6 @@ instance Applicative (MaybeErr err) where (<*>) = ap instance Monad (MaybeErr err) where - return = A.pure Succeeded v >>= k = k v Failed e >>= _ = Failed e -- cgit v1.2.1