rust/tests/ui/rfcs/rfc-2632-const-trait-impl/call-generic-method-fail.rs
2023-08-14 02:17:30 +00:00

11 lines
201 B
Rust

// FIXME(effects)
// check-pass
#![feature(const_trait_impl, effects)]
pub const fn equals_self<T: PartialEq>(t: &T) -> bool {
*t == *t
// (remove this) ~^ ERROR can't compare
}
fn main() {}