rust/tests/ui/lint/rfc-2383-lint-reason/multiple_expect_attrs.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

15 lines
387 B
Rust
Raw Normal View History

// check-pass
#![feature(lint_reasons)]
#![warn(unused)]
#[warn(unused_variables)]
#[expect(unused_variables)]
//~^ WARNING this lint expectation is unfulfilled [unfulfilled_lint_expectations]
//~| NOTE `#[warn(unfulfilled_lint_expectations)]` on by default
#[allow(unused_variables)]
#[expect(unused_variables)] // Only this expectation will be fulfilled
fn main() {
let x = 2;
}