1 // aux-build:ident-mac.rs
3 #![feature(c_variadic)]
4 #![allow(anonymous_parameters)]
6 extern crate ident_mac;
11 extern "C" { fn ffi(#[id] arg1: i32, #[id] ...); }
12 //~^ ERROR expected non-macro attribute, found attribute macro
13 //~| ERROR expected non-macro attribute, found attribute macro
15 unsafe extern "C" fn cvar(arg1: i32, #[id] mut args: ...) {}
16 //~^ ERROR expected non-macro attribute, found attribute macro
18 type Alias = extern "C" fn(#[id] u8, #[id] ...);
19 //~^ ERROR expected non-macro attribute, found attribute macro
20 //~| ERROR expected non-macro attribute, found attribute macro
22 fn free(#[id] arg1: u8) {
23 //~^ ERROR expected non-macro attribute, found attribute macro
24 let lam = |#[id] W(x), #[id] y: usize| ();
25 //~^ ERROR expected non-macro attribute, found attribute macro
26 //~| ERROR expected non-macro attribute, found attribute macro
30 fn inherent1(#[id] self, #[id] arg1: u8) {}
31 //~^ ERROR expected non-macro attribute, found attribute macro
32 //~| ERROR expected non-macro attribute, found attribute macro
33 fn inherent2(#[id] &self, #[id] arg1: u8) {}
34 //~^ ERROR expected non-macro attribute, found attribute macro
35 //~| ERROR expected non-macro attribute, found attribute macro
36 fn inherent3<'a>(#[id] &'a mut self, #[id] arg1: u8) {}
37 //~^ ERROR expected non-macro attribute, found attribute macro
38 //~| ERROR expected non-macro attribute, found attribute macro
39 fn inherent4<'a>(#[id] self: Box<Self>, #[id] arg1: u8) {}
40 //~^ ERROR expected non-macro attribute, found attribute macro
41 //~| ERROR expected non-macro attribute, found attribute macro
42 fn issue_64682_associated_fn<'a>(#[id] arg1: u8, #[id] arg2: u8) {}
43 //~^ ERROR expected non-macro attribute, found attribute macro
44 //~| ERROR expected non-macro attribute, found attribute macro
48 fn trait1(#[id] self, #[id] arg1: u8);
49 //~^ ERROR expected non-macro attribute, found attribute macro
50 //~| ERROR expected non-macro attribute, found attribute macro
51 fn trait2(#[id] &self, #[id] arg1: u8);
52 //~^ ERROR expected non-macro attribute, found attribute macro
53 //~| ERROR expected non-macro attribute, found attribute macro
54 fn trait3<'a>(#[id] &'a mut self, #[id] arg1: u8);
55 //~^ ERROR expected non-macro attribute, found attribute macro
56 //~| ERROR expected non-macro attribute, found attribute macro
57 fn trait4<'a>(#[id] self: Box<Self>, #[id] arg1: u8, #[id] Vec<u8>);
58 //~^ ERROR expected non-macro attribute, found attribute macro
59 //~| ERROR expected non-macro attribute, found attribute macro
60 //~| ERROR expected non-macro attribute, found attribute macro
61 fn issue_64682_associated_fn<'a>(#[id] arg1: u8, #[id] arg2: u8);
62 //~^ ERROR expected non-macro attribute, found attribute macro
63 //~| ERROR expected non-macro attribute, found attribute macro