summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoseph C. Sible <3439-josephcsible@users.noreply.gitlab.haskell.org>2020-04-26 14:23:59 -0400
committerMarge Bot <ben+marge-bot@smart-cactus.org>2020-05-08 15:29:40 -0400
commit926d2aab83dc6068cba76f71a19b040eddc6dee9 (patch)
tree7800e1b3f4f91b38dd2628c35eb66ca04a3a702d
parentcdd229fff24ab19a41dd2af218108dd8c514fff7 (diff)
downloadhaskell-926d2aab83dc6068cba76f71a19b040eddc6dee9.tar.gz
Apply more suggestions from Simon Jakobi
-rw-r--r--libraries/base/Data/Monoid.hs8
1 files changed, 4 insertions, 4 deletions
diff --git a/libraries/base/Data/Monoid.hs b/libraries/base/Data/Monoid.hs
index 7c299019d9..f8925cbfb7 100644
--- a/libraries/base/Data/Monoid.hs
+++ b/libraries/base/Data/Monoid.hs
@@ -234,9 +234,9 @@ instance (Applicative f, Bounded a) => Bounded (Ap f a) where
maxBound = pure maxBound
-- | Note that even if the underlying 'Num' and 'Applicative' instances are
--- lawful, for most 'Applicative's, this instance will not be lawful. It's
--- particularly tempting to use this with lists, but then these laws all fail
--- to hold:
+-- lawful, for most 'Applicative's, this instance will not be lawful. If you use
+-- this instance with the list 'Applicative', the following customary laws will
+-- not hold:
--
-- Commutativity:
--
@@ -259,7 +259,7 @@ instance (Applicative f, Bounded a) => Bounded (Ap f a) where
-- >>> (Ap [1,2] * 3) + (Ap [1,2] * 4)
-- Ap {getAp = [7,11,10,14]}
--
--- | @since 4.12.0.0
+-- @since 4.12.0.0
instance (Applicative f, Num a) => Num (Ap f a) where
(+) = liftA2 (+)
(*) = liftA2 (*)