rust/tests/ui/deprecation/issue-66340-deprecated-attr-non-meta-grammar.rs
2023-01-11 09:32:08 +00:00

12 lines
308 B
Rust

// The original problem in #66340 was that `find_deprecation_generic`
// called `attr.meta().unwrap()` under the assumption that the attribute
// was a well-formed `MetaItem`.
fn main() {
foo()
}
#[deprecated(note = test)]
//~^ ERROR expected unsuffixed literal or identifier, found `test`
fn foo() {}