Skip to content

Commit 1a52c1f

Browse files
committed
Note some limitations of automatic std links
1 parent 52e0ff3 commit 1a52c1f

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

docs/authoring.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,15 @@ Explicit namespace disambiguation is also supported:
109109
[`std::vec`](mod@std::vec)
110110
```
111111

112+
Beware there are some limitations, for example:
113+
114+
- Links to rexports from `std_arch` don't work due to <https://github.com/rust-lang/rust/issues/96506>.
115+
- Links to keywords aren't supported.
116+
- Links to trait impls where the trait is not in the prelude doesn't work. Traits must be in scope, and there currently isn't a way to add those.
117+
- If there are multiple generic implementations, it will link to one randomly (see <https://github.com/rust-lang/rust/issues/76895>).
118+
119+
When running into a rustdoc limitation, consider manually linking to the correct page using a relative link. For example, `../std/arch/macro.is_x86_feature_detected.html`.
120+
112121
[intra]: https://doc.rust-lang.org/rustdoc/write-documentation/linking-to-items-by-name.html
113122

114123
### Admonitions

0 commit comments

Comments
 (0)