git.iko.soy/typeable/pandoc
on master help sign in
Fixed bug in RST reader, which would choke on: "p. one\ntwo\n".

Added some try's in ordered list parsers. git-svn-id: https://pandoc.googlecode.com/svn/trunk@1191 788f1e2b-df1e-0410-8736-df70ead52e1b

commit42359e63c9a7ddeb67e639296fc20a1e3eaac7dc authorfiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> dateThu 17 Jan 2008, 02:14 (19 years ago) parent8f8888d
1 file changed+2−2
Text/Pandoc/Readers/RST.hs+2−2
Text/Pandoc/Readers/RST.hs+2−2
@@ -378,7 +378,7 @@ indentWith num = do
378378 (try (char '\t' >> count (num - tabStop) (char ' '))) ]
379379
380380-- parse raw text for one list item, excluding start marker and continuations
381−rawListItem start = do
381+rawListItem start = try $ do
382382 markerLength <- start
383383 firstLine <- manyTill anyChar newline
384384 restLines <- many (listLine markerLength)
@@ -408,7 +408,7 @@ listItem start = try $ do
408408 updateState (\st -> st {stateParserContext = oldContext})
409409 return parsed
410410
411−orderedList = do
411+orderedList = try $ do
412412 (start, style, delim) <- lookAhead (anyOrderedListMarker >>~ spaceChar)
413413 items <- many1 (listItem (orderedListStart style delim))
414414 let items' = compactify items