]> git.proxmox.com Git - rustc.git/blob - src/test/ui/macros/trace_faulty_macros.stderr
New upstream version 1.55.0+dfsg1
[rustc.git] / src / test / ui / macros / trace_faulty_macros.stderr
1 error: no rules expected the token `bcd`
2 --> $DIR/trace_faulty_macros.rs:7:26
3 |
4 LL | macro_rules! my_faulty_macro {
5 | ---------------------------- when calling this macro
6 LL | () => {
7 LL | my_faulty_macro!(bcd);
8 | ^^^ no rules expected this token in macro call
9 ...
10 LL | my_faulty_macro!();
11 | ------------------- in this macro invocation
12 |
13 = note: this error originates in the macro `my_faulty_macro` (in Nightly builds, run with -Z macro-backtrace for more info)
14
15 note: trace_macro
16 --> $DIR/trace_faulty_macros.rs:31:5
17 |
18 LL | my_faulty_macro!();
19 | ^^^^^^^^^^^^^^^^^^^
20 |
21 = note: expanding `my_faulty_macro! { }`
22 = note: to `my_faulty_macro! (bcd) ;`
23 = note: expanding `my_faulty_macro! { bcd }`
24
25 error: recursion limit reached while expanding `my_recursive_macro!`
26 --> $DIR/trace_faulty_macros.rs:22:9
27 |
28 LL | my_recursive_macro!();
29 | ^^^^^^^^^^^^^^^^^^^^^^
30 ...
31 LL | my_recursive_macro!();
32 | ---------------------- in this macro invocation
33 |
34 = help: consider adding a `#![recursion_limit="8"]` attribute to your crate (`trace_faulty_macros`)
35 = note: this error originates in the macro `my_recursive_macro` (in Nightly builds, run with -Z macro-backtrace for more info)
36
37 note: trace_macro
38 --> $DIR/trace_faulty_macros.rs:32:5
39 |
40 LL | my_recursive_macro!();
41 | ^^^^^^^^^^^^^^^^^^^^^^
42 |
43 = note: expanding `my_recursive_macro! { }`
44 = note: to `my_recursive_macro! () ;`
45 = note: expanding `my_recursive_macro! { }`
46 = note: to `my_recursive_macro! () ;`
47 = note: expanding `my_recursive_macro! { }`
48 = note: to `my_recursive_macro! () ;`
49 = note: expanding `my_recursive_macro! { }`
50 = note: to `my_recursive_macro! () ;`
51
52 error: expected expression, found `A { a: a, b: 0, c: _, .. }`
53 --> $DIR/trace_faulty_macros.rs:16:9
54 |
55 LL | $a
56 | ^^ expected expression
57 ...
58 LL | let a = pat_macro!();
59 | ------------ in this macro invocation
60 |
61 = note: this error originates in the macro `pat_macro` (in Nightly builds, run with -Z macro-backtrace for more info)
62
63 error[E0774]: `derive` may only be applied to `struct`s, `enum`s and `union`s
64 --> $DIR/trace_faulty_macros.rs:42:1
65 |
66 LL | #[derive(Debug)]
67 | ^^^^^^^^^^^^^^^^ not applicable here
68 LL | fn use_derive_macro_as_attr() {}
69 | -------------------------------- not a `struct`, `enum` or `union`
70
71 note: trace_macro
72 --> $DIR/trace_faulty_macros.rs:36:13
73 |
74 LL | let a = pat_macro!();
75 | ^^^^^^^^^^^^
76 |
77 = note: expanding `pat_macro! { }`
78 = note: to `pat_macro! (A { a : a, b : 0, c : _, .. }) ;`
79 = note: expanding `pat_macro! { A { a : a, b : 0, c : _, .. } }`
80 = note: to `A { a: a, b: 0, c: _, .. }`
81
82 error: aborting due to 4 previous errors
83
84 For more information about this error, try `rustc --explain E0774`.