Skip to main content

## INVALID_DOC_ATTRIBUTES

# Static INVALID_DOC_ATTRIBUTES

Source

    pub static INVALID_DOC_ATTRIBUTES: &'static Lint

Expand description

The `invalid_doc_attributes` lint detects when the `#[doc(...)]` is misused.

#### §Example

ⓘ

    #![deny(warnings)]

    pub mod submodule {
        #![doc(test(no_crate_inject))]
    }

{{produces}}

#### §Explanation

Previously, incorrect usage of the `#[doc(..)]` attribute was not being validated. Usually these should be rejected as a hard error, but this lint was introduced to avoid breaking any existing crates which included them.