]> git.proxmox.com Git - rustc.git/blame - src/test/ui/parser/issue-73568-lifetime-after-mut.stderr
New upstream version 1.55.0+dfsg1
[rustc.git] / src / test / ui / parser / issue-73568-lifetime-after-mut.stderr
CommitLineData
1b1a35ee
XL
1error: lifetime must precede `mut`
2 --> $DIR/issue-73568-lifetime-after-mut.rs:2:13
3 |
4LL | fn x<'a>(x: &mut 'a i32){}
5 | ^^^^^^^ help: place the lifetime before `mut`: `&'a mut`
6
7error[E0178]: expected a path on the left-hand side of `+`, not `&mut 'a`
8 --> $DIR/issue-73568-lifetime-after-mut.rs:14:13
9 |
10LL | fn y<'a>(y: &mut 'a + Send) {
11 | ^^^^^^^^^^^^^^ help: try adding parentheses: `&mut ('a + Send)`
12
13error: lifetime must precede `mut`
14 --> $DIR/issue-73568-lifetime-after-mut.rs:6:22
15 |
16LL | fn w<$lt>(w: &mut $lt i32) {}
17 | ^^^^^^^^ help: place the lifetime before `mut`: `&$lt mut`
18...
19LL | mac!('a);
20 | --------- in this macro invocation
21 |
17df50a5 22 = note: this error originates in the macro `mac` (in Nightly builds, run with -Z macro-backtrace for more info)
1b1a35ee
XL
23
24error[E0423]: expected value, found trait `Send`
17df50a5 25 --> $DIR/issue-73568-lifetime-after-mut.rs:19:28
1b1a35ee
XL
26 |
27LL | let z = y as &mut 'a + Send;
28 | ^^^^ not a value
29
30warning: trait objects without an explicit `dyn` are deprecated
31 --> $DIR/issue-73568-lifetime-after-mut.rs:14:18
32 |
33LL | fn y<'a>(y: &mut 'a + Send) {
34 | ^^ help: use `dyn`: `dyn 'a`
35 |
36 = note: `#[warn(bare_trait_objects)]` on by default
136023e0 37 = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021!
17df50a5 38 = note: for more information, see issue #80165 <https://github.com/rust-lang/rust/issues/80165>
1b1a35ee
XL
39
40warning: trait objects without an explicit `dyn` are deprecated
17df50a5 41 --> $DIR/issue-73568-lifetime-after-mut.rs:19:23
1b1a35ee
XL
42 |
43LL | let z = y as &mut 'a + Send;
44 | ^^ help: use `dyn`: `dyn 'a`
17df50a5 45 |
136023e0 46 = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021!
17df50a5 47 = note: for more information, see issue #80165 <https://github.com/rust-lang/rust/issues/80165>
1b1a35ee
XL
48
49error[E0224]: at least one trait is required for an object type
50 --> $DIR/issue-73568-lifetime-after-mut.rs:14:18
51 |
52LL | fn y<'a>(y: &mut 'a + Send) {
53 | ^^
54
55error: aborting due to 5 previous errors; 2 warnings emitted
56
57Some errors have detailed explanations: E0178, E0224, E0423.
58For more information about an error, try `rustc --explain E0178`.