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