summaryrefslogtreecommitdiffstats
path: root/tests/ui/macros/issue-84195-lint-anon-const.rs
blob: 71c76832015289fdbe188735b715a3c1f2031398 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// Regression test for issue #84195
// Checks that we properly fire lints that occur inside
// anon consts.

#![deny(semicolon_in_expressions_from_macros)]

macro_rules! len {
    () => { 0; }; //~  ERROR trailing semicolon
                  //~| WARN this was previously accepted
}

fn main() {
    let val: [u8; len!()] = [];
}