aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2018-06-30 11:45:49 +0200
committerJohn MacFarlane <jgm@berkeley.edu>2018-06-30 11:45:49 +0200
commit016e0a09e2e2ffa823157a28a3a7f0268b9c6f42 (patch)
tree991225dba7a1c2d9fcdb733177746ae26d29319d /src
parentce83a128e1ceee879069d5e0dda8402aa2cbed32 (diff)
downloadpandoc-016e0a09e2e2ffa823157a28a3a7f0268b9c6f42.tar.gz
RST writer: don't treat 'example' as a syntax name.
This fixes conversions from org with example blocks. Closes #4748.
Diffstat (limited to 'src')
-rw-r--r--src/Text/Pandoc/Writers/RST.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Writers/RST.hs b/src/Text/Pandoc/Writers/RST.hs
index 1fd984a6d..a2f2739a0 100644
--- a/src/Text/Pandoc/Writers/RST.hs
+++ b/src/Text/Pandoc/Writers/RST.hs
@@ -273,7 +273,8 @@ blockToRST (CodeBlock (_,classes,kvs) str) = do
then return $ prefixed "> " (text str) $$ blankline
else return $
(case [c | c <- classes,
- c `notElem` ["sourceCode","literate","numberLines"]] of
+ c `notElem` ["sourceCode","literate","numberLines",
+ "number-lines","example"]] of
[] -> "::"
(lang:_) -> (".. code:: " <> text lang) $$ numberlines)
$+$ nest 3 (text str) $$ blankline