rust/tests/ui/pattern/mut_preserve_binding_mode_2024_lint.stderr

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

32 lines
953 B
Plaintext
Raw Normal View History

2024-04-05 23:28:34 -04:00
error: dereferencing `mut` binding
2024-04-14 11:12:52 -04:00
--> $DIR/mut_preserve_binding_mode_2024_lint.rs:9:13
2024-04-05 23:28:34 -04:00
|
LL | let Foo(mut a) = &Foo(0);
| ^^^^^ `mut` dereferences the type of this binding
|
help: this will change in edition 2024
2024-04-14 11:12:52 -04:00
--> $DIR/mut_preserve_binding_mode_2024_lint.rs:9:13
2024-04-05 23:28:34 -04:00
|
LL | let Foo(mut a) = &Foo(0);
| ^^^^^
note: the lint level is defined here
2024-04-14 11:12:52 -04:00
--> $DIR/mut_preserve_binding_mode_2024_lint.rs:4:11
2024-04-05 23:28:34 -04:00
|
LL | #![forbid(dereferencing_mut_binding)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^
error: dereferencing `mut` binding
2024-04-14 11:12:52 -04:00
--> $DIR/mut_preserve_binding_mode_2024_lint.rs:13:13
2024-04-05 23:28:34 -04:00
|
LL | let Foo(mut a) = &mut Foo(0);
| ^^^^^ `mut` dereferences the type of this binding
|
help: this will change in edition 2024
2024-04-14 11:12:52 -04:00
--> $DIR/mut_preserve_binding_mode_2024_lint.rs:13:13
2024-04-05 23:28:34 -04:00
|
LL | let Foo(mut a) = &mut Foo(0);
| ^^^^^
error: aborting due to 2 previous errors