Skip to content

Commit

Permalink
Merge pull request #359 from data61/recommend-applicative
Browse files Browse the repository at this point in the history
Recommend applicative over monad
  • Loading branch information
tonymorris authored Jul 24, 2019
2 parents 2da6fcd + 6829e74 commit 2967d02
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Course/MoreParser.hs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ spaces =
-- | Write a function that applies the given parser, then parses 0 or more spaces,
-- then produces the result of the original parser.
--
-- /Tip:/ Use the monad instance.
-- /Tip:/ Use the applicative instance or the monad instance.
--
-- >>> parse (tok (is 'a')) "a bc"
-- Result >bc< 'a'
Expand Down Expand Up @@ -198,7 +198,7 @@ noneof =
-- | Write a function that applies the first parser, runs the third parser keeping the result,
-- then runs the second parser and produces the obtained result.
--
-- /Tip:/ Use the monad instance.
-- /Tip:/ Use the applicative instance or the monad instance
--
-- >>> parse (between (is '[') (is ']') character) "[a]"
-- Result >< 'a'
Expand Down

0 comments on commit 2967d02

Please sign in to comment.