-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-intra-doc-linksArea: Intra-doc links, the ability to link to items in docs by nameArea: Intra-doc links, the ability to link to items in docs by nameA-macrosArea: All kinds of macros (custom derive, macro_rules!, proc macros, ..)Area: All kinds of macros (custom derive, macro_rules!, proc macros, ..)C-bugCategory: This is a bug.Category: This is a bug.P-lowLow priorityLow priorityT-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.Relevant to the rustdoc team, which will review and decide on the PR/issue.
Description
mod bar {
macro_rules! str {() => {}}
}
pub mod foo {
use std::path::{Path, PathBuf};
pub struct Foo(PathBuf);
impl std::ops::Deref for Foo {
type Target = Path;
fn deref(&self) -> &Path { &self.0 }
}
}
In the documentation of Foo::to_str()
inherited from the deref impl, the documentation contains a link to [`&str`](str)
that fails due to the presence of a str!
macro in another module, even though that macro isn't accessible. (Even if it was, it shouldn't be affecting the resolution of an intra-doc link in the standard library.)
Meta
rustc --version --verbose
:
rustc 1.51.0-nightly (0e63af5da 2021-01-31)
binary: rustc
commit-hash: 0e63af5da3400ace48a0345117980473fd21ad73
commit-date: 2021-01-31
host: x86_64-unknown-linux-gnu
release: 1.51.0-nightly
LLVM version: 11.0.1
Metadata
Metadata
Assignees
Labels
A-intra-doc-linksArea: Intra-doc links, the ability to link to items in docs by nameArea: Intra-doc links, the ability to link to items in docs by nameA-macrosArea: All kinds of macros (custom derive, macro_rules!, proc macros, ..)Area: All kinds of macros (custom derive, macro_rules!, proc macros, ..)C-bugCategory: This is a bug.Category: This is a bug.P-lowLow priorityLow priorityT-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.Relevant to the rustdoc team, which will review and decide on the PR/issue.