]> git.lizzy.rs Git - rust.git/blob - src/test/ui/attributes/key-value-expansion-on-mac.rs
Rollup merge of #101388 - compiler-errors:issue-101376, r=fee1-dead
[rust.git] / src / test / ui / attributes / key-value-expansion-on-mac.rs
1 #![feature(rustc_attrs)]
2
3 #[rustc_dummy = stringify!(a)] // OK
4 macro_rules! bar {
5     () => {};
6 }
7
8 // FIXME?: `bar` here expands before `stringify` has a chance to expand.
9 // `#[rustc_dummy = ...]` is validated and dropped during expansion of `bar`,
10 // the "unexpected expression" errors comes from the validation.
11 #[rustc_dummy = stringify!(b)] //~ ERROR unexpected expression: `stringify!(b)`
12 bar!();
13
14 fn main() {}