git.iko.soy/typeable/pandoc
on master help sign in
Case-insensitive parsing of URI schemes.
5971721John MacFarlane
src/Text/Pandoc/Parsing.hs+1−1
@@ -395,7 +395,7 @@ schemes = ["coap","doi","javascript","aaa","aaas","about","acap","cap","cid",
395-- | Parses a URI. Returns pair of original and URI-escaped version.
395-- | Parses a URI. Returns pair of original and URI-escaped version.
396uri :: Parser [Char] st (String, String)
396uri :: Parser [Char] st (String, String)
397uri = try $ do
397uri = try $ do
398− scheme <- oneOfStrings schemes
398+ scheme <- oneOfStringsCI schemes
399 char ':'
399 char ':'
400 -- /^[\/\w\u0080-\uffff]+|%[A-Fa-f0-9]+|&#?\w+;|(?:[,]+|[\S])[%&~\w\u0080-\uffff]/
400 -- /^[\/\w\u0080-\uffff]+|%[A-Fa-f0-9]+|&#?\w+;|(?:[,]+|[\S])[%&~\w\u0080-\uffff]/
401 -- We allow punctuation except at the end, since
401 -- We allow punctuation except at the end, since