about summary refs log tree commit diff
path: root/src/tools/clippy/tests/ui/crashes/ice-3462.rs
blob: e06eccdf142caa91555afbbe0bc97792cf2cbdc5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
//@ check-pass

#![expect(clippy::disallowed_names)]

// Test for https://github.com/rust-lang/rust-clippy/issues/3462

enum Foo {
    Bar,
    Baz,
}

fn bar(foo: Foo) {
    macro_rules! baz {
        () => {
            if let Foo::Bar = foo {}
        };
    }

    baz!();
    baz!();
}

fn main() {}