aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b>2010-03-01 22:37:06 +0000
committerfiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b>2010-03-01 22:37:06 +0000
commitf5e00c50b8ec7c5687feae6278869205a1d6ab60 (patch)
treefc7c131f5c90838c8710a3f6d6d10fff5e4de15c
parent50583e9e3f586ef93edf6108fde9b1801b231088 (diff)
downloadpandoc-f5e00c50b8ec7c5687feae6278869205a1d6ab60.tar.gz
Markdown reader: Allow footnotes to be indented < 4 spaces.
This fixes a regression. A test case has been added in testsuite.txt. git-svn-id: https://pandoc.googlecode.com/svn/trunk@1859 788f1e2b-df1e-0410-8736-df70ead52e1b
-rw-r--r--src/Text/Pandoc/Readers/Markdown.hs4
-rw-r--r--tests/testsuite.txt4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/Text/Pandoc/Readers/Markdown.hs b/src/Text/Pandoc/Readers/Markdown.hs
index 029b40101..f674ee204 100644
--- a/src/Text/Pandoc/Readers/Markdown.hs
+++ b/src/Text/Pandoc/Readers/Markdown.hs
@@ -222,8 +222,8 @@ referenceTitle = try $ do
notFollowedBy (noneOf ")\n")))
return $ decodeCharacterReferences tit
-noteMarker :: GenParser Char st [Char]
-noteMarker = string "[^" >> manyTill (noneOf " \t\n") (char ']')
+noteMarker :: GenParser Char ParserState [Char]
+noteMarker = skipNonindentSpaces >> string "[^" >> manyTill (noneOf " \t\n") (char ']')
rawLine :: GenParser Char ParserState [Char]
rawLine = do
diff --git a/tests/testsuite.txt b/tests/testsuite.txt
index 5688e1afe..7f6e89449 100644
--- a/tests/testsuite.txt
+++ b/tests/testsuite.txt
@@ -715,5 +715,5 @@ footnote (as with list items).
This paragraph should not be part of the note, as it is not indented.
-[^1]: Here is the footnote. It can go anywhere after the footnote
-reference. It need not be placed at the end of the document.
+ [^1]: Here is the footnote. It can go anywhere after the footnote
+ reference. It need not be placed at the end of the document.