diff options
author | Fumiaki Kinoshita <fumiexcel@gmail.com> | 2020-07-15 21:12:07 +0900 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2020-10-14 18:06:12 -0400 |
commit | e60ae8a38394370fd8818ad004a101466fc7d2dc (patch) | |
tree | 6eff280150db65ae373aba5d50f550180b99983b /testsuite/tests/determinism | |
parent | bf2411a3c198cb2df93a9e0aa0c3b8297f47058d (diff) | |
download | haskell-e60ae8a38394370fd8818ad004a101466fc7d2dc.tar.gz |
Add -Wnoncanonical-{monad,monoid}-instances to standardWarnings
-------------------------
Metric Decrease:
T12425
Metric Increase:
T17516
-------------------------
Diffstat (limited to 'testsuite/tests/determinism')
-rw-r--r-- | testsuite/tests/determinism/determ019/A.hs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/testsuite/tests/determinism/determ019/A.hs b/testsuite/tests/determinism/determ019/A.hs index 9984780204..3b69438fd7 100644 --- a/testsuite/tests/determinism/determ019/A.hs +++ b/testsuite/tests/determinism/determ019/A.hs @@ -40,7 +40,6 @@ newtype StateT s m a = StateT { runStateT :: s -> m (a, s) } instance MonadFix m => Monad (StateT s m) where - return x = StateT $ \s -> pure (x, s) m >>= f = StateT $ \s -> do rec (x, s'') <- runStateT m s' @@ -49,7 +48,7 @@ instance MonadFix m => Monad (StateT s m) where instance MonadFix m => Applicative (StateT s m) where (<*>) = ap - pure = return + pure x = StateT $ \s -> pure (x, s) instance Functor m => Functor (StateT s m) where -- this instance is hand-written |