From 21328a87718818d78c658c87a2c42298453cc45f Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Thu, 19 Oct 2017 15:58:12 -0700 Subject: LaTeX reader: be more forgiving in parsing command options. This was needed, for example, to make some minted options work. --- src/Text/Pandoc/Readers/LaTeX.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Text/Pandoc/Readers/LaTeX.hs b/src/Text/Pandoc/Readers/LaTeX.hs index 54c19b622..5ac114b19 100644 --- a/src/Text/Pandoc/Readers/LaTeX.hs +++ b/src/Text/Pandoc/Readers/LaTeX.hs @@ -769,7 +769,7 @@ dolstinline = do keyval :: PandocMonad m => LP m (String, String) keyval = try $ do Tok _ Word key <- satisfyTok isWordTok - let isSpecSym (Tok _ Symbol t) = t `elem` [".",":","-","|","\\"] + let isSpecSym (Tok _ Symbol t) = t /= "]" && t /= "," isSpecSym _ = False optional sp val <- option [] $ do @@ -2095,7 +2095,7 @@ environments = M.fromList , ("BVerbatim", fancyverbEnv "BVerbatim") , ("lstlisting", do attr <- parseListingsOptions <$> option [] keyvals codeBlockWith attr <$> verbEnv "lstlisting") - , ("minted", minted) + , ("minted", minted) , ("obeylines", obeylines) , ("displaymath", mathEnvWith para Nothing "displaymath") , ("equation", mathEnvWith para Nothing "equation") -- cgit v1.2.3