git.iko.soy/typeable/pandoc
on master help sign in
Fixed bug in uri parser.

The bug prevented an autolink at the end of a string (e.g. at the end of a line block line) from counting as a link. Closes #711.

commitc4b93bc3e7ea2006dbe3273ed06b66129775982e authorJohn MacFarlane <fiddlosopher@gmail.com> dateSun 20 Jan 2013, 20:23 (14 years ago) parent65528e4
1 file changed+1−1
src/Text/Pandoc/Parsing.hs+1−1
src/Text/Pandoc/Parsing.hs+1−1
@@ -415,7 +415,7 @@ uri = try $ do
415415 let uriChunk = skipMany1 wordChar
416416 <|> percentEscaped
417417 <|> entity
418− <|> (try $ punct >> notFollowedBy (satisfy $ not . isWordChar))
418+ <|> (try $ punct >> lookAhead (satisfy isWordChar) >> return ())
419419 str <- snd `fmap` withRaw (skipMany1 ( () <$
420420 (enclosed (char '(') (char ')') uriChunk
421421 <|> enclosed (char '{') (char '}') uriChunk