diff options
author | Mateusz Kowalczyk <fuuzetsu@fuuzetsu.co.uk> | 2014-05-06 13:39:23 +0200 |
---|---|---|
committer | Mateusz Kowalczyk <fuuzetsu@fuuzetsu.co.uk> | 2014-05-06 13:50:31 +0200 |
commit | e8756e5bfcd128817b7942cb439ee3287dd0637a (patch) | |
tree | 3f40b20693c69a09573a86d8ebd675a438623f45 /src/Haddock/Parser.hs | |
parent | 70ce2cbf11ea6c861b5597527f768039d0571bf2 (diff) |
Remove no longer necessary parser error handling.
We can now drop some Maybe tests and even lets us strip an error
handling monad away in a few places.
Diffstat (limited to 'src/Haddock/Parser.hs')
-rw-r--r-- | src/Haddock/Parser.hs | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/src/Haddock/Parser.hs b/src/Haddock/Parser.hs index 720f442b..ea4b7a3f 100644 --- a/src/Haddock/Parser.hs +++ b/src/Haddock/Parser.hs @@ -13,13 +13,12 @@ -- Stability : experimental -- Portability : portable -module Haddock.Parser ( module Documentation.Haddock.Parser - , parseParasMaybe - , parseStringMaybe +module Haddock.Parser ( parseParas + , parseString , parseIdent ) where -import Documentation.Haddock.Parser +import qualified Documentation.Haddock.Parser as P import DynFlags (DynFlags) import FastString (mkFastString) import Documentation.Haddock.Types @@ -29,13 +28,11 @@ import RdrName (RdrName) import SrcLoc (mkRealSrcLoc, unLoc) import StringBuffer (stringToStringBuffer) -{-# DEPRECATED parseParasMaybe "use `parseParas` instead" #-} -parseParasMaybe :: DynFlags -> String -> Maybe (DocH mod RdrName) -parseParasMaybe d = Just . overIdentifier (parseIdent d) . parseParas +parseParas :: DynFlags -> String -> DocH mod RdrName +parseParas d = P.overIdentifier (parseIdent d) . P.parseParas -{-# DEPRECATED parseStringMaybe "use `parseString` instead" #-} -parseStringMaybe :: DynFlags -> String -> Maybe (DocH mod RdrName) -parseStringMaybe d = Just . overIdentifier (parseIdent d) . parseString +parseString :: DynFlags -> String -> DocH mod RdrName +parseString d = P.overIdentifier (parseIdent d) . P.parseString parseIdent :: DynFlags -> String -> Maybe RdrName parseIdent dflags str0 = |