rust/src/test/ui/partialeq_help.rs

8 lines
97 B
Rust

fn foo<T: PartialEq>(a: &T, b: T) {
a == b; //~ ERROR E0277
}
fn main() {
foo(&1, 1);
}