2023-04-16 11:12:37 +00:00
|
|
|
// known-bug: #110395
|
2021-07-19 18:50:47 +08:00
|
|
|
#![feature(const_trait_impl)]
|
|
|
|
|
2022-08-28 06:27:31 +00:00
|
|
|
#[const_trait]
|
2021-07-19 18:50:47 +08:00
|
|
|
trait MyPartialEq {
|
|
|
|
fn eq(&self, other: &Self) -> bool;
|
|
|
|
}
|
|
|
|
|
2021-08-25 15:21:55 +00:00
|
|
|
impl<T: ~const PartialEq> const MyPartialEq for T {
|
2021-07-19 18:50:47 +08:00
|
|
|
fn eq(&self, other: &Self) -> bool {
|
|
|
|
PartialEq::eq(self, other)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|