summaryrefslogtreecommitdiffstats
path: root/tests/ui/binop/eq-vec.rs
blob: 17ce8df8564253b7757a25db2b870716fe793290 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
fn main() {
    #[derive(Debug)]
    enum Foo {
        //~^ HELP consider annotating `Foo` with `#[derive(PartialEq)]`
        Bar,
        Qux,
    }

    let vec1 = vec![Foo::Bar, Foo::Qux];
    let vec2 = vec![Foo::Bar, Foo::Qux];
    assert_eq!(vec1, vec2);
    //~^ ERROR binary operation `==` cannot be applied to type `Vec<Foo>`
}