git.iko.soy/typeable/pandoc
on master help sign in
LaTeX writer: clean up options parser.

Make sure that we require the closing bracket.

commit4438ff17fb2ce8a1d9991e5c530aaaf5547b7bc4 authorJesse Rosenthal <jrosenthal@jhu.edu> dateThu 18 Feb 2016, 23:35 (11 years ago) parent4112b32
1 file changed+4−3
src/Text/Pandoc/Writers/LaTeX.hs+4−3
src/Text/Pandoc/Writers/LaTeX.hs+4−3
@@ -1259,10 +1259,11 @@ deNote x = x
12591259pDocumentOptions :: P.Parsec String () [String]
12601260pDocumentOptions = do
12611261 P.char '['
1262− P.sepBy
1263− (P.many $
1264− P.spaces *> P.noneOf (" ,]" :: String) <* P.spaces)
1262+ opts <- P.sepBy
1263+ (P.many $ P.spaces *> P.noneOf (" ,]" :: String) <* P.spaces)
12651264 (P.char ',')
1265+ P.char ']'
1266+ return opts
12661267
12671268pDocumentClass :: P.Parsec String () String
12681269pDocumentClass =