rust/tests/ui/impl-trait/issues/issue-84919.rs
2024-01-07 18:00:03 +00:00

10 lines
171 B
Rust

trait Trait {}
impl Trait for () {}
fn foo<'a: 'a>() {
let _x: impl Trait = ();
//~^ `impl Trait` is not allowed in the type of variable bindings
}
fn main() {}