diff options
author | John MacFarlane <jgm@berkeley.edu> | 2012-07-27 16:00:27 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2012-07-27 16:00:27 -0700 |
commit | f0b9d52fd3fcdd61e1ea7f5ac98eefe7e502cf8a (patch) | |
tree | bdf4eacf84a0181adf98a62594f00bd1c6c63547 /src/Text/Pandoc/Readers | |
parent | ec7c1631a57ae48e3763bfb4de1288423d9e3aea (diff) | |
download | pandoc-f0b9d52fd3fcdd61e1ea7f5ac98eefe7e502cf8a.tar.gz |
Markdown reader: Added sensitivity to Ext_example_lists.
Diffstat (limited to 'src/Text/Pandoc/Readers')
-rw-r--r-- | src/Text/Pandoc/Readers/Markdown.hs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/Markdown.hs b/src/Text/Pandoc/Readers/Markdown.hs index 7f4ed6d3e..545f34ca1 100644 --- a/src/Text/Pandoc/Readers/Markdown.hs +++ b/src/Text/Pandoc/Readers/Markdown.hs @@ -592,9 +592,10 @@ listItem start = try $ do orderedList :: Parser [Char] ParserState Block orderedList = try $ do (start, style, delim) <- lookAhead anyOrderedListStart - unless ((style == DefaultStyle || style == Decimal) && + unless ((style == DefaultStyle || style == Decimal || style == Example) && (delim == DefaultDelim || delim == Period)) $ guardEnabled Ext_fancy_lists + when (style == Example) $ guardEnabled Ext_example_lists items <- many1 $ listItem $ try $ do optional newline -- if preceded by a Plain block in a list context skipNonindentSpaces @@ -1024,6 +1025,7 @@ ltSign = do exampleRef :: Parser [Char] ParserState Inline exampleRef = try $ do + guardEnabled Ext_example_lists char '@' lab <- many1 (alphaNum <|> oneOf "-_") -- We just return a Str. These are replaced with numbers |