summaryrefslogtreecommitdiffstats
path: root/tests/ui/parser/bad-interpolated-block.rs
blob: c6d7ae383b247ad496c9ef6066af97ee2147debc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
fn main() {}

macro_rules! m {
    ($b:block) => {
        'lab: $b; //~ ERROR cannot use a `block` macro fragment here
        unsafe $b; //~ ERROR cannot use a `block` macro fragment here
        |x: u8| -> () $b; //~ ERROR cannot use a `block` macro fragment here
    }
}

fn foo() {
    m!({});
}