From 508aab0bd555b4ca7632a78957ebb91c758f0a7e Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Tue, 14 Nov 2017 22:05:47 -0800 Subject: Text.Pandoc.Parsing.uri: allow `&` and `=` as word characters. This fixes a bug where pandoc would stop parsing a URI with an empty attribute: for example, `&a=&b=` wolud stop at `a`. (The uri parser tries to guess which punctuation characters are part of the URI and which might be punctuation after it.) Closes #4068. --- test/command/4068.md | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 test/command/4068.md (limited to 'test') diff --git a/test/command/4068.md b/test/command/4068.md new file mode 100644 index 000000000..7b43a7084 --- /dev/null +++ b/test/command/4068.md @@ -0,0 +1,9 @@ +``` +pandoc -f mediawiki -t native +[https://domain.com/script.php?a=1&b=2&c=&d=4 open productname bugs] + +[http://domain.com?a=. open productname bugs] +^D +[Para [Link ("",[],[]) [Str "open",Space,Str "productname",Space,Str "bugs"] ("https://domain.com/script.php?a=1&b=2&c=&d=4","")] +,Para [Str "[",Link ("",[],[]) [Str "http://domain.com?a="] ("http://domain.com?a=",""),Str ".",Space,Str "open",Space,Str "productname",Space,Str "bugs]"]] +``` -- cgit v1.2.3