Addendum to the fix to issue #242.

The previous fix resulted in bird tracks being included in
both html and html+lhs renderings of literate haskell sections
when pandoc was compiled without highlighting support. This change make
pandoc without highlighting behave like pandoc with highlighting: the
bird tracks are used only if html+lhs output is specified.
This commit is contained in:
John MacFarlane 2010-07-07 10:28:25 -07:00
parent 6a68dbe5ae
commit 1cd99f9880

View file

@ -285,7 +285,7 @@ blockToHtml opts (CodeBlock (id',classes,keyvals) rawCode) = do
attrs = [theclass (unwords classes') | not (null classes')] ++
[prefixedId opts id' | not (null id')] ++
map (\(x,y) -> strAttr x y) keyvals
addBird = if "literate" `elem` classes
addBird = if "literate" `elem` classes'
then unlines . map ("> " ++) . lines
else unlines . lines
in return $ pre ! attrs $ thecode <<