rust/tests/ui/async-await/in-trait/generics-mismatch.rs

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

13 lines
233 B
Rust
Raw Normal View History

//@ edition: 2021
trait Foo {
async fn foo<T>();
}
impl Foo for () {
async fn foo<const N: usize>() {}
//~^ ERROR: associated function `foo` has an incompatible generic parameter for trait `Foo` [E0053]
}
fn main() {}