Skip to content

Commit 08d3a74

Browse files
committed
Allow for parentheses after macro intra-doc-links
1 parent 5db778a commit 08d3a74

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/librustdoc/passes/collect_intra_doc_links.rs

+3
Original file line numberDiff line numberDiff line change
@@ -602,6 +602,9 @@ impl<'a, 'tcx> DocFolder for LinkCollector<'a, 'tcx> {
602602
kind = Some(ValueNS);
603603
disambiguator = Some(&prefix[..prefix.len() - 1]);
604604
link.trim_start_matches(prefix)
605+
} else if link.ends_with("!()") {
606+
kind = Some(MacroNS);
607+
link.trim_end_matches("!()")
605608
} else if link.ends_with("()") {
606609
kind = Some(ValueNS);
607610
disambiguator = Some("fn");

0 commit comments

Comments
 (0)