2022-02-14 16:10:22 +00:00
|
|
|
//@ edition:2018
|
2024-11-06 17:50:24 +00:00
|
|
|
//@compile-flags: --diagnostic-width=300
|
2022-02-14 16:10:22 +00:00
|
|
|
|
2023-04-12 13:32:15 +00:00
|
|
|
#![feature(impl_trait_in_assoc_type)]
|
2022-02-14 16:10:22 +00:00
|
|
|
|
|
|
|
pub trait Bar {
|
|
|
|
type E: Copy;
|
|
|
|
|
|
|
|
fn foo<T>() -> Self::E;
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<S> Bar for S {
|
|
|
|
type E = impl std::marker::Copy;
|
|
|
|
fn foo<T>() -> Self::E {
|
2022-11-25 08:53:58 +00:00
|
|
|
//~^ ERROR : Copy` is not satisfied [E0277]
|
2025-04-01 21:48:41 +00:00
|
|
|
//~| ERROR type parameter `T` is part of concrete type
|
2022-02-14 16:10:22 +00:00
|
|
|
async {}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|