1
Fork 0
rust/src/test/ui/rfc-2632-const-trait-impl/call-generic-in-impl.rs
2021-07-19 19:51:44 +08:00

15 lines
285 B
Rust

// check-pass
#![feature(const_fn_trait_bound)]
#![feature(const_trait_impl)]
trait MyPartialEq {
fn eq(&self, other: &Self) -> bool;
}
impl<T: PartialEq> const MyPartialEq for T {
fn eq(&self, other: &Self) -> bool {
PartialEq::eq(self, other)
}
}
fn main() {}