Commit 6c9a580
committed
rustdoc: Strip broken links in summaries
The primary reason to do this is because intra-doc links are treated as
"broken" in the summary since the resolution context is not available.
Previously, search results with intra-doc links would look like:
> This method returns an \[`Ordering`\]
but now they look like:
> This method returns an `Ordering`
as search results with regular links do.
The one drawback I can see is if people are using `[` and `]` literally,
but I think that case is much rarer than using intra-doc links, and they
can and should escape the brackets with a backslash or use inline code.
Plus, this is just for summaries.1 parent d1206f9 commit 6c9a580
1 file changed
+16
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1035 | 1035 | | |
1036 | 1036 | | |
1037 | 1037 | | |
1038 | | - | |
| 1038 | + | |
| 1039 | + | |
| 1040 | + | |
| 1041 | + | |
| 1042 | + | |
| 1043 | + | |
| 1044 | + | |
| 1045 | + | |
1039 | 1046 | | |
1040 | 1047 | | |
1041 | 1048 | | |
| |||
1113 | 1120 | | |
1114 | 1121 | | |
1115 | 1122 | | |
1116 | | - | |
| 1123 | + | |
| 1124 | + | |
| 1125 | + | |
| 1126 | + | |
| 1127 | + | |
| 1128 | + | |
| 1129 | + | |
| 1130 | + | |
1117 | 1131 | | |
1118 | 1132 | | |
1119 | 1133 | | |
| |||
0 commit comments