2021-02-28 13:51:44 -06:00
|
|
|
PRINT-DERIVE INPUT (DISPLAY): struct Foo
|
|
|
|
{
|
|
|
|
val :
|
|
|
|
[bool ;
|
|
|
|
{
|
|
|
|
let a = #[rustc_dummy(first)] #[rustc_dummy(second)]
|
2021-05-01 14:54:47 -05:00
|
|
|
{ #! [allow(unused)] 30 } ; 0
|
2020-11-28 17:33:17 -06:00
|
|
|
}]
|
2021-02-28 13:51:44 -06:00
|
|
|
}
|
|
|
|
PRINT-DERIVE INPUT (DEBUG): TokenStream [
|
|
|
|
Ident {
|
|
|
|
ident: "struct",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:17:9: 17:15 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Ident {
|
|
|
|
ident: "Foo",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:17:16: 17:19 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Group {
|
|
|
|
delimiter: Brace,
|
|
|
|
stream: TokenStream [
|
|
|
|
Ident {
|
|
|
|
ident: "val",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:18:13: 18:16 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Punct {
|
|
|
|
ch: ':',
|
|
|
|
spacing: Alone,
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:18:16: 18:17 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Group {
|
|
|
|
delimiter: Bracket,
|
|
|
|
stream: TokenStream [
|
|
|
|
Ident {
|
|
|
|
ident: "bool",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:18:19: 18:23 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Punct {
|
|
|
|
ch: ';',
|
|
|
|
spacing: Alone,
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:18:23: 18:24 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Group {
|
|
|
|
delimiter: Brace,
|
|
|
|
stream: TokenStream [
|
|
|
|
Ident {
|
|
|
|
ident: "let",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:19:17: 19:20 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Ident {
|
|
|
|
ident: "a",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:19:21: 19:22 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Punct {
|
|
|
|
ch: '=',
|
|
|
|
spacing: Alone,
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:19:23: 19:24 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Punct {
|
|
|
|
ch: '#',
|
|
|
|
spacing: Alone,
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:19:25: 19:26 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Group {
|
|
|
|
delimiter: Bracket,
|
|
|
|
stream: TokenStream [
|
|
|
|
Ident {
|
|
|
|
ident: "rustc_dummy",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:19:48: 19:59 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Group {
|
|
|
|
delimiter: Parenthesis,
|
|
|
|
stream: TokenStream [
|
|
|
|
Ident {
|
|
|
|
ident: "first",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:19:60: 19:65 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
],
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:19:59: 19:66 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
],
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:19:25: 19:26 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Punct {
|
|
|
|
ch: '#',
|
|
|
|
spacing: Alone,
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:26:13: 26:14 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Group {
|
|
|
|
delimiter: Bracket,
|
|
|
|
stream: TokenStream [
|
|
|
|
Ident {
|
|
|
|
ident: "rustc_dummy",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:26:36: 26:47 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Group {
|
|
|
|
delimiter: Parenthesis,
|
|
|
|
stream: TokenStream [
|
|
|
|
Ident {
|
|
|
|
ident: "second",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:26:48: 26:54 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
],
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:26:47: 26:55 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
],
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:26:13: 26:14 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Group {
|
|
|
|
delimiter: Brace,
|
|
|
|
stream: TokenStream [
|
|
|
|
Punct {
|
|
|
|
ch: '#',
|
2020-11-28 17:33:17 -06:00
|
|
|
spacing: Alone,
|
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:27:5: 27:6 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Punct {
|
|
|
|
ch: '!',
|
|
|
|
spacing: Alone,
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:27:6: 27:7 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Group {
|
|
|
|
delimiter: Bracket,
|
|
|
|
stream: TokenStream [
|
|
|
|
Ident {
|
|
|
|
ident: "allow",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:27:29: 27:34 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Group {
|
|
|
|
delimiter: Parenthesis,
|
|
|
|
stream: TokenStream [
|
|
|
|
Ident {
|
|
|
|
ident: "unused",
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:27:35: 27:41 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
],
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:27:34: 27:42 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
],
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:27:5: 27:6 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Literal {
|
|
|
|
kind: Integer,
|
|
|
|
symbol: "30",
|
|
|
|
suffix: None,
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:28:5: 28:7 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
],
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:26:58: 29:2 (#0),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Punct {
|
|
|
|
ch: ';',
|
|
|
|
spacing: Alone,
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:19:74: 19:75 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
Literal {
|
|
|
|
kind: Integer,
|
|
|
|
symbol: "0",
|
|
|
|
suffix: None,
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:20:17: 20:18 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
],
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:18:25: 21:14 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
],
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:18:18: 21:15 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
],
|
2020-11-28 17:33:17 -06:00
|
|
|
span: $DIR/macro-rules-derive-cfg.rs:17:20: 22:10 (#4),
|
2021-02-28 13:51:44 -06:00
|
|
|
},
|
|
|
|
]
|