rust/tests/ui/coercion/mut-mut-wont-coerce.stderr

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

20 lines
619 B
Plaintext
Raw Normal View History

error[E0308]: mismatched types
--> $DIR/mut-mut-wont-coerce.rs:36:14
|
LL | make_foo(&mut &mut *result);
| -------- ^^^^^^^^^^^^^^^^^ expected `*mut *mut Foo`, found `&mut &mut Foo`
| |
| arguments to this function are incorrect
|
= note: expected raw pointer `*mut *mut Foo`
found mutable reference `&mut &mut Foo`
note: function defined here
--> $DIR/mut-mut-wont-coerce.rs:30:4
|
LL | fn make_foo(_: *mut *mut Foo) {
| ^^^^^^^^ ----------------
error: aborting due to 1 previous error
For more information about this error, try `rustc --explain E0308`.