diff options
author | Austin Seipp <aseipp@pobox.com> | 2013-09-08 09:02:04 -0500 |
---|---|---|
committer | Austin Seipp <aseipp@pobox.com> | 2013-09-08 09:30:10 -0500 |
commit | 0b1bea4360d730ae4c91092bc94bc541631dbc84 (patch) | |
tree | d87feed052483dccadd73a158ec386955be25707 /testsuite/tests/mdo | |
parent | 8859e1e3e4e6c695a4e9a1659fc0ec935141324a (diff) | |
download | haskell-0b1bea4360d730ae4c91092bc94bc541631dbc84.tar.gz |
Fix most AMP warnings.
Authored-by: David Luposchainsky <dluposchainsky@gmail.com>
Signed-off-by: Austin Seipp <aseipp@pobox.com>
Diffstat (limited to 'testsuite/tests/mdo')
-rw-r--r-- | testsuite/tests/mdo/should_fail/mdofail004.hs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/testsuite/tests/mdo/should_fail/mdofail004.hs b/testsuite/tests/mdo/should_fail/mdofail004.hs index 37cd757312..929785423c 100644 --- a/testsuite/tests/mdo/should_fail/mdofail004.hs +++ b/testsuite/tests/mdo/should_fail/mdofail004.hs @@ -10,8 +10,18 @@ module Main (main) where import Control.Monad.Fix +import Control.Applicative (Applicative(..)) +import Control.Monad (liftM, ap) + data X a = X a deriving Show +instance Functor X where + fmap = liftM + +instance Applicative X where + pure = return + (<*>) = ap + instance Monad X where return = X (X a) >>= f = f a |