diff options
author | Greg Maslov <gmaslov@bootis.org> | 2012-03-25 05:03:35 -0400 |
---|---|---|
committer | Greg Maslov <gmaslov@bootis.org> | 2012-03-25 05:03:35 -0400 |
commit | 4a1ba8ce49ffc3c2a154721dc18fc48896f97f59 (patch) | |
tree | b53fcae960d48c8984e1cc41039a5a9369fa8611 /src/Text/Pandoc | |
parent | 618dc294f93f1865dcdfbfda21003745b4d6b389 (diff) | |
download | pandoc-4a1ba8ce49ffc3c2a154721dc18fc48896f97f59.tar.gz |
Oops! Forgot to munch whitespace / ignore body after directive.
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r-- | src/Text/Pandoc/Readers/RST.hs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/RST.hs b/src/Text/Pandoc/Readers/RST.hs index 2fbf11cf7..35fe5d768 100644 --- a/src/Text/Pandoc/Readers/RST.hs +++ b/src/Text/Pandoc/Readers/RST.hs @@ -539,13 +539,16 @@ bulletList = many1 (listItem bulletListStart) >>= defaultRoleBlock :: GenParser Char ParserState Block defaultRoleBlock = try $ do - string ".. default-role:: " + string ".. default-role::" + -- doesn't enforce any restrictions on the role name; embedded spaces shouldn't be allowed, for one role <- manyTill anyChar newline >>= return . removeLeadingTrailingSpace updateState $ \s -> s { stateRstDefaultRole = if null role then stateRstDefaultRole defaultParserState else role } + -- skip body of the directive if it exists + many $ blanklines <|> (spaceChar >> manyTill anyChar newline) return Null -- |