-
Couldn't load subscription status.
- Fork 13.9k
rustdoc: refine cross-crate impl inlining #33002
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
The thread-local isn't needed and consists of mostly empty fields which were just used to move the data into `html::render::CACHE_KEY`.
78f29ce to
9589d72
Compare
src/librustdoc/clean/inline.rs
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After thinking more about this, this probably doesn't matter since an impl in an external crate can't reference a local type or trait (right??).
This changes the current rule that impls within `doc(hidden)` modules aren't inlined, to only inlining impls where the implemented trait and type are reachable in documentation.
|
Hmm, this probably doesn't yet fix this since this isn't related to inlining. #![crate_type="lib"]
pub trait Bar {}
#[doc(hidden)]
pub mod hidden {
pub struct Foo;
}
// impl shown in `foo::Bar`s implementors section (but without link)
impl Bar for hidden::Foo {}edit: filed as #33069 |
rustdoc: refine cross-crate impl inlining This changes the current rule that impls within `doc(hidden)` modules aren't inlined, to only inlining impls where the implemented trait and type are reachable in documentation. fixes #14586 fixes #31948 .. and also applies the reachability checking to cross-crate links. fixes #28480 r? @alexcrichton
This changes the current rule that impls within
doc(hidden)modules aren't inlined, to only inlining impls where the implemented trait and type are reachable in documentation.fixes #14586
fixes #31948
.. and also applies the reachability checking to cross-crate links.
fixes #28480
r? @alexcrichton