mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-23 07:14:28 +00:00
17 lines
263 B
Rust
17 lines
263 B
Rust
//@ edition: 2021
|
|
|
|
#![deny(dead_code)]
|
|
|
|
pub fn foo() {
|
|
let closure = || {
|
|
fn a() {} //~ ERROR function `a` is never used
|
|
};
|
|
closure()
|
|
}
|
|
|
|
pub async fn async_foo() {
|
|
const A: usize = 1; //~ ERROR constant `A` is never used
|
|
}
|
|
|
|
fn main() {}
|