]> git.lizzy.rs Git - rust.git/blob - tests/ui/macros/attr-empty-expr.rs
Auto merge of #106952 - petrochenkov:docglob, r=notriddle,GuillaumeGomez
[rust.git] / tests / ui / macros / attr-empty-expr.rs
1 // AST-based macro attributes expanding to an empty expression produce an error and not ICE.
2
3 #![feature(custom_test_frameworks)]
4 #![feature(stmt_expr_attributes)]
5 #![feature(test)]
6
7 fn main() {
8     let _ = #[test] 0; //~ ERROR removing an expression is not supported in this position
9     let _ = #[bench] 1; //~ ERROR removing an expression is not supported in this position
10     let _ = #[test_case] 2; //~ ERROR removing an expression is not supported in this position
11 }