Skip to content

missing_doc should not deny on invisible internal items #9777

Description

@dcrewi

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]
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions