Rollup merge of #43632 - ruuda:allow-long-relative-urls, r=Mark-Simulacrum

Detect relative urls in tidy check

This came up in #43631: there can be long relative urls in Markdown comments, that do not start with `http://` or `https://`, so the tidy check will not detect them as urls and complain about the line length. This PR adds detection of relative urls starting with `../`.
This commit is contained in:
Guillaume Gomez 2017-08-11 10:20:17 +02:00 committed by GitHub
commit 643231313a

View File

@ -83,7 +83,7 @@ fn line_is_url(line: &str) -> bool {
=> state = EXP_END,
(EXP_URL, w)
if w.starts_with("http://") || w.starts_with("https://")
if w.starts_with("http://") || w.starts_with("https://") || w.starts_with("../")
=> state = EXP_END,
(_, _) => return false,