git.iko.soy/typeable/pandoc
on master help sign in
LaTeX writer: Fix description lists contining highlighted code.

Closes #4662.

commit966bd94ba268216f9d1492287638fd0b725dd503 authorJohn MacFarlane <jgm@berkeley.edu> dateSat 29 Sep 2018, 23:29 (8 years ago) parent190ee27
1 file changed+4−2
src/Text/Pandoc/Writers/LaTeX.hs+4−2
src/Text/Pandoc/Writers/LaTeX.hs+4−2
@@ -870,9 +870,11 @@ defListItemToLaTeX (term, defs) = do
870870 else term'
871871 def' <- liftM vsep $ mapM blockListToLaTeX defs
872872 return $ case defs of
873− ((Header{} : _) : _) ->
873+ ((Header{} : _) : _) ->
874874 "\\item" <> brackets term'' <> " ~ " $$ def'
875− _ ->
875+ ((CodeBlock{} : _) : _) -> -- see #4662
876+ "\\item" <> brackets term'' <> " ~ " $$ def'
877+ _ ->
876878 "\\item" <> brackets term'' $$ def'
877879
878880-- | Craft the section header, inserting the secton reference, if supplied.