summaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/Parsing.hs
diff options
context:
space:
mode:
authorJohn MacFarlane <fiddlosopher@gmail.com>2012-07-25 11:08:06 -0700
committerJohn MacFarlane <fiddlosopher@gmail.com>2012-07-25 11:08:06 -0700
commitdfa19061abc24a3e95b9b37e4f9484d902110899 (patch)
tree22c233b704fd99be18711cce8dcf08964096dab6 /src/Text/Pandoc/Parsing.hs
parentda3702357dc9a310b460c82411fe5b8c870416d5 (diff)
Options -> ReaderOptions.
Better to keep reader and writer options separate.
Diffstat (limited to 'src/Text/Pandoc/Parsing.hs')
-rw-r--r--src/Text/Pandoc/Parsing.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Text/Pandoc/Parsing.hs b/src/Text/Pandoc/Parsing.hs
index 2d0fef7c3..3ed2644ba 100644
--- a/src/Text/Pandoc/Parsing.hs
+++ b/src/Text/Pandoc/Parsing.hs
@@ -392,7 +392,7 @@ nullBlock = anyChar >> return Null
failIfStrict :: Parsec [a] ParserState ()
failIfStrict = do
state <- getState
- if optionStrict (stateOptions state) then fail "strict mode" else return ()
+ if readerStrict (stateOptions state) then fail "strict mode" else return ()
-- | Fail unless we're in literate haskell mode.
failUnlessLHS :: Parsec [tok] ParserState ()
@@ -689,7 +689,7 @@ testStringWith parser str = UTF8.putStrLn $ show $
-- | Parsing options.
data ParserState = ParserState
- { stateOptions :: Options, -- ^ User options
+ { stateOptions :: ReaderOptions, -- ^ User options
stateParseRaw :: Bool, -- ^ Parse raw HTML and LaTeX?
stateParserContext :: ParserContext, -- ^ Inside list?
stateQuoteContext :: QuoteContext, -- ^ Inside quoted environment?
@@ -795,7 +795,7 @@ lookupKeySrc table key = case M.lookup key table of
-- | Fail unless we're in "smart typography" mode.
failUnlessSmart :: Parsec [tok] ParserState ()
-failUnlessSmart = getState >>= guard . optionSmart . stateOptions
+failUnlessSmart = getState >>= guard . readerSmart . stateOptions
smartPunctuation :: Parsec [Char] ParserState Inline
-> Parsec [Char] ParserState Inline