aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/Readers
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2020-10-08 09:11:25 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2020-10-08 09:12:29 -0700
commit2566ff662473b4c4095ffe5d3bdbb0325a70b6a3 (patch)
tree62e4ab401d0c98c87e3668034eb5e9e2aff8bef9 /src/Text/Pandoc/Readers
parentd1e1898c5226d334f49fafb829f79508161108dc (diff)
downloadpandoc-2566ff662473b4c4095ffe5d3bdbb0325a70b6a3.tar.gz
Qualify some uses of fail to avoid ambiguity.
Diffstat (limited to 'src/Text/Pandoc/Readers')
-rw-r--r--src/Text/Pandoc/Readers/Metadata.hs12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/Text/Pandoc/Readers/Metadata.hs b/src/Text/Pandoc/Readers/Metadata.hs
index 76fbd8110..0d49a7fa8 100644
--- a/src/Text/Pandoc/Readers/Metadata.hs
+++ b/src/Text/Pandoc/Readers/Metadata.hs
@@ -42,13 +42,13 @@ yamlBsToMeta pMetaValue bstr = do
Right [] -> return . return $ mempty
Right [YAML.Doc (YAML.Scalar _ YAML.SNull)]
-> return . return $ mempty
- Right _ -> fail "expected YAML object"
+ Right _ -> Prelude.fail "expected YAML object"
Left (yamlpos, err')
-> do pos <- getPosition
setPosition $ incSourceLine
(setSourceColumn pos (YE.posColumn yamlpos))
(YE.posLine yamlpos - 1)
- fail err'
+ Prelude.fail err'
fakePos :: YAML.Pos
fakePos = YAML.Pos (-1) (-1) 1 0
@@ -87,16 +87,16 @@ yamlBsToRefs pMetaValue idpred bstr =
sequence <$>
mapM (yamlToMetaValue pMetaValue) (filter g ns)
Just _ ->
- fail "expecting sequence in 'references' field"
+ Prelude.fail "expecting sequence in 'references' field"
Nothing ->
- fail "expecting 'references' field"
+ Prelude.fail "expecting 'references' field"
Right [] -> return . return $ mempty
Right [YAML.Doc (YAML.Scalar _ YAML.SNull)]
-> return . return $ mempty
- Right _ -> fail "expecting YAML object"
+ Right _ -> Prelude.fail "expecting YAML object"
Left (_pos, err')
- -> fail err'
+ -> Prelude.fail err'
nodeToKey :: YAML.Node YE.Pos -> Maybe Text