aboutsummaryrefslogtreecommitdiff
path: root/haddock-library/src/Documentation/Haddock
diff options
context:
space:
mode:
authorAlec Theriault <alec.theriault@gmail.com>2019-05-26 15:19:27 -0400
committerAlec Theriault <alec.theriault@gmail.com>2019-05-26 17:57:52 -0400
commit91f55209065497c8cd0d0a23e5ed5561410b4df0 (patch)
tree8d8a4731da6a5baeebf56d6688f5181e12cc49ed /haddock-library/src/Documentation/Haddock
parent3dceaa39ad2333c988efcefc718b3c82ade70f21 (diff)
Release haddock-2.23, haddock-library-1.8.0
Tentatively adjust bounds and changelogs for the release to be bundled with GHC 8.8.1.
Diffstat (limited to 'haddock-library/src/Documentation/Haddock')
-rw-r--r--haddock-library/src/Documentation/Haddock/Parser/Identifier.hs10
1 files changed, 5 insertions, 5 deletions
diff --git a/haddock-library/src/Documentation/Haddock/Parser/Identifier.hs b/haddock-library/src/Documentation/Haddock/Parser/Identifier.hs
index 7bc98b62..a83e5abf 100644
--- a/haddock-library/src/Documentation/Haddock/Parser/Identifier.hs
+++ b/haddock-library/src/Documentation/Haddock/Parser/Identifier.hs
@@ -109,7 +109,7 @@ takeIdentifier input = listToMaybe $ do
(cl, input'''') <- maybeToList (T.uncons input''')
guard (cl == '\'' || cl == '`')
- pure (ns, op, ident, cl, input'''')
+ return (ns, op, ident, cl, input'''')
where
@@ -122,21 +122,21 @@ takeIdentifier input = listToMaybe $ do
, c' == ',' || c' == ')'
-> do let (commas, t'') = T.span (== ',') t'
(')', t''') <- maybeToList (T.uncons t'')
- pure (T.take (T.length commas + 2) t, t''')
+ return (T.take (T.length commas + 2) t, t''')
-- Parenthesized
'(' -> do (n, t'' ) <- general False 0 [] t'
(')', t''') <- maybeToList (T.uncons t'')
- pure (T.take (n + 2) t, t''')
+ return (T.take (n + 2) t, t''')
-- Backticked
'`' -> do (n, t'' ) <- general False 0 [] t'
('`', t''') <- maybeToList (T.uncons t'')
- pure (T.take (n + 2) t, t''')
+ return (T.take (n + 2) t, t''')
-- Unadorned
_ -> do (n, t'' ) <- general False 0 [] t
- pure (T.take n t, t'')
+ return (T.take n t, t'')
-- | Parse out a possibly qualified operator or identifier
general :: Bool -- ^ refuse inputs starting with operators