# Static rustc_lint_defs::builtin::UNFULFILLED_LINT_EXPECTATIONS

source ·

    pub static UNFULFILLED_LINT_EXPECTATIONS: &Lint

Expand description

The `unfulfilled_lint_expectations` lint detects lint trigger expectations that have not been fulfilled.

#### §Example

    #![feature(lint_reasons)]

    #[expect(unused_variables)]
    let x = 10;
    println!("{}", x);

{{produces}}

#### §Explanation

It was expected that the marked code would emit a lint. This expectation has not been fulfilled.

The `expect` attribute can be removed if this is intended behavior otherwise it should be investigated why the expected lint is no longer issued.

In rare cases, the expectation might be emitted at a different location than shown in the shown code snippet. In most cases, the `#[expect]` attribute works when added to the outer scope. A few lints can only be expected on a crate level.

Part of RFC 2383. The progress is being tracked in #54503