rust/src/test/ui/malformed/malformed-derive-entry.rs
Esteban Küber 24160171e4 Tweak macro parse errors when reaching EOF during macro call parse
- Add detail on origin of current parser when reaching EOF and stop
  saying "found <eof>" and point at the end of macro calls
- Handle empty `cfg_attr` attribute
- Reword empty `derive` attribute error
2019-05-24 11:49:33 -07:00

14 lines
310 B
Rust

#[derive(Copy(Bad))] //~ ERROR expected one of `)`, `,`, or `::`, found `(`
struct Test1;
#[derive(Copy="bad")] //~ ERROR expected one of `)`, `,`, or `::`, found `=`
struct Test2;
#[derive()] //~ WARNING empty trait list
struct Test3;
#[derive] //~ ERROR bad `derive` attribute
struct Test4;
fn main() {}