File: issue-65122-mac-invoc-in-mut-patterns.stderr

package info (click to toggle)
rustc 1.85.0%2Bdfsg3-1
  • links: PTS, VCS
  • area: main
  • in suites: experimental, forky, sid, trixie
  • size: 893,396 kB
  • sloc: xml: 158,127; python: 35,830; javascript: 19,497; cpp: 19,002; sh: 17,245; ansic: 13,127; asm: 4,376; makefile: 1,051; perl: 29; lisp: 29; ruby: 19; sql: 11
file content (59 lines) | stat: -rw-r--r-- 1,973 bytes parent folder | download | duplicates (3)
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
error: `mut` must be followed by a named binding
  --> $DIR/issue-65122-mac-invoc-in-mut-patterns.rs:6:13
   |
LL |         let mut $eval = ();
   |             ^^^^
...
LL |     mac1! { does_not_exist!() }
   |     --------------------------- in this macro invocation
   |
   = note: `mut` may be followed by `variable` and `variable @ pattern`
   = note: this error originates in the macro `mac1` (in Nightly builds, run with -Z macro-backtrace for more info)
help: remove the `mut` prefix
   |
LL -         let mut $eval = ();
LL +         let $eval = ();
   |

error: expected identifier, found `does_not_exist!()`
  --> $DIR/issue-65122-mac-invoc-in-mut-patterns.rs:13:17
   |
LL |         let mut $eval = ();
   |                 ^^^^^ expected identifier
...
LL |     mac2! { does_not_exist!() }
   |     --------------------------- in this macro invocation
   |
   = note: this error originates in the macro `mac2` (in Nightly builds, run with -Z macro-backtrace for more info)

error: `mut` must be followed by a named binding
  --> $DIR/issue-65122-mac-invoc-in-mut-patterns.rs:13:13
   |
LL |         let mut $eval = ();
   |             ^^^
...
LL |     mac2! { does_not_exist!() }
   |     --------------------------- in this macro invocation
   |
   = note: `mut` may be followed by `variable` and `variable @ pattern`
   = note: this error originates in the macro `mac2` (in Nightly builds, run with -Z macro-backtrace for more info)
help: remove the `mut` prefix
   |
LL -         let mut $eval = ();
LL +         let  $eval = ();
   |

error: cannot find macro `does_not_exist` in this scope
  --> $DIR/issue-65122-mac-invoc-in-mut-patterns.rs:22:13
   |
LL |     mac2! { does_not_exist!() }
   |             ^^^^^^^^^^^^^^

error: cannot find macro `does_not_exist` in this scope
  --> $DIR/issue-65122-mac-invoc-in-mut-patterns.rs:20:13
   |
LL |     mac1! { does_not_exist!() }
   |             ^^^^^^^^^^^^^^

error: aborting due to 5 previous errors