You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I expect missing_doc lint to only check that publicly-visible code is documented. The following gets caught by the lint checker when I think that it shouldn't:
#[deny(missing_doc)]
mod internal_impl {
pub fn secret_sauce() {
// unstable, messy, or unsafe code
}
}
pub mod public_interface {
use super::internal_impl;
/// I do something.
pub fn do_something() {
// [do stuff]
internal_impl::secret_sauce();
// [do more stuff]
}
}
The text was updated successfully, but these errors were encountered:
On an implementation note, I would recommend using the results of the analysis from the privacy pass of the compiler instead of trying to re-implement it in a lint pass.
One tricky case to keep in mind is that you may pub use an overall private item, and the item should probably still get documented. i.e.
pubuse imp::foo;mod imp {// this should require documentation even though impl::foo isn't a public pathpubfnfoo(){}}
Don't lint `explicit_auto_deref` when the initial type is neither a reference, nor a receiver
fixesrust-lang#9901fixesrust-lang#9777
changelog: `explicit_auto_deref`: Don't lint when the initial value is neither a reference, nor a receiver
I expect
missing_doc
lint to only check that publicly-visible code is documented. The following gets caught by the lint checker when I think that it shouldn't:The text was updated successfully, but these errors were encountered: