Avoid some common false positives in intra doc link checking

This commit is contained in:
Manish Goregaokar 2019-03-08 21:12:12 -08:00
parent b2ea6c86ae
commit a4ea08420c

View File

@ -291,6 +291,12 @@ impl<'a, 'tcx, 'rcx> DocFolder for LinkCollector<'a, 'tcx, 'rcx> {
if ori_link.contains('/') {
continue;
}
// [] is mostly likely not supposed to be a link
if ori_link.is_empty() {
continue;
}
let link = ori_link.replace("`", "");
let (def, fragment) = {
let mut kind = PathKind::Unknown;