about summary refs log tree commit diff
path: root/tests/ui/proc-macro/debug/dump-debug.rs
blob: b20cd2dc948a27d4050f72b50f3ec3d9b7d1c03d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
//@ run-pass
//@ proc-macro: macro-dump-debug.rs

extern crate macro_dump_debug;
use macro_dump_debug::dump_debug;

dump_debug! {
    ident   // ident
    r#ident // raw ident
    ,       // alone punct
    ==>     // joint punct
    ()      // empty group
    [_]     // nonempty group

    // unsuffixed literals
    0
    1.0
    "S"
    b"B"
    r"R"
    r##"R"##
    br"BR"
    br##"BR"##
    'C'
    b'B'

    // suffixed literals
    0q
    1.0q
    "S"q
    b"B"q
    r"R"q
    r##"R"##q
    br"BR"q
    br##"BR"##q
    'C'q
    b'B'q
}

fn main() {}