git.iko.soy/typeable/pandoc
on master help sign in
Added stateWarnings.

It is not connected to anything yet.

commit7ef07ea3fc89a33210cbf92c6bb3a3f553a3f174 authorJohn MacFarlane <fiddlosopher@gmail.com> dateThu 3 Jan 2013, 20:52 (14 years ago) parent5a4f7ec
1 file changed+4−2
src/Text/Pandoc/Parsing.hs+4−2
src/Text/Pandoc/Parsing.hs+4−2
@@ -726,7 +726,8 @@ data ParserState = ParserState
726726 stateExamples :: M.Map String Int, -- ^ Map from example labels to numbers
727727 stateHasChapters :: Bool, -- ^ True if \chapter encountered
728728 stateMacros :: [Macro], -- ^ List of macros defined so far
729− stateRstDefaultRole :: String -- ^ Current rST default interpreted text role
729+ stateRstDefaultRole :: String, -- ^ Current rST default interpreted text role
730+ stateWarnings :: [String] -- ^ Warnings generated by the parser
730731 }
731732
732733instance Default ParserState where
@@ -753,7 +754,8 @@ defaultParserState =
753754 stateExamples = M.empty,
754755 stateHasChapters = False,
755756 stateMacros = [],
756− stateRstDefaultRole = "title-reference"}
757+ stateRstDefaultRole = "title-reference",
758+ stateWarnings = []}
757759
758760getOption :: (ReaderOptions -> a) -> Parser s ParserState a
759761getOption f = (f . stateOptions) `fmap` getState