rust/tests/ui/lint/dead-code/allow-or-expect-dead_code-114557-3.rs
tcpdumppy 69aafd21f5 tests: fix some typos in comment
Signed-off-by: tcpdumppy <847462026@qq.com>
2025-03-07 10:50:31 +08:00

13 lines
297 B
Rust

//@ check-pass
// this test makes sure that the `unfulfilled_lint_expectations` lint
// is being emitted for `foo` as foo is not dead code, it's pub
#![warn(dead_code)] // to override compiletest
#[expect(dead_code)]
//~^ WARN this lint expectation is unfulfilled
pub fn foo() {}
fn main() {}