diff options
author | John MacFarlane <jgm@berkeley.edu> | 2013-10-29 10:57:48 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2013-10-29 10:57:48 -0700 |
commit | ab0ffe6549261313410207a0b5beba9284135962 (patch) | |
tree | 8abdf73185ab8c08c336eb1655309f18558a5153 /src/Text | |
parent | a6aaff102ef75bf02c9a3256a2a750abae78d0b6 (diff) | |
download | pandoc-ab0ffe6549261313410207a0b5beba9284135962.tar.gz |
Markdown reader: Yaml block must start immediately after `---`.
If there's a blank line after `---`, we interpreted it as
a horizontal rule.
Diffstat (limited to 'src/Text')
-rw-r--r-- | src/Text/Pandoc/Readers/Markdown.hs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Readers/Markdown.hs b/src/Text/Pandoc/Readers/Markdown.hs index 5456f25b5..8f804f863 100644 --- a/src/Text/Pandoc/Readers/Markdown.hs +++ b/src/Text/Pandoc/Readers/Markdown.hs @@ -227,6 +227,7 @@ yamlMetaBlock = try $ do pos <- getPosition string "---" blankline + notFollowedBy blankline -- if --- is followed by a blank it's an HRULE rawYamlLines <- manyTill anyLine stopLine -- by including --- and ..., we allow yaml blocks with just comments: let rawYaml = unlines ("---" : (rawYamlLines ++ ["..."])) |