]> git.lizzy.rs Git - rust.git/blob - tests/ui/macros/meta-variable-depth-outside-repeat.rs
Rollup merge of #104505 - WaffleLapkin:no-double-spaces-in-comments, r=jackh726
[rust.git] / tests / ui / macros / meta-variable-depth-outside-repeat.rs
1 #![feature(macro_metavar_expr)]
2
3 macro_rules! metavar {
4     ( $i:expr ) => {
5         ${length(0)}
6         //~^ ERROR meta-variable expression `length` with depth parameter must be called inside of a macro repetition
7     };
8 }
9
10 const _: i32 = metavar!(0);
11
12 fn main() {}