rust-clippy/tests/ui/crashes/needless_pass_by_value-w-late-bound.rs
2023-08-22 17:18:11 +02:00

10 lines
247 B
Rust

// https://github.com/rust-lang/rust/issues/107147
#![warn(clippy::needless_pass_by_value)]
struct Foo<'a>(&'a [(); 100]);
fn test(x: Foo<'_>) {}
//~^ ERROR: this argument is passed by value, but not consumed in the function body
fn main() {}