]> git.proxmox.com Git - rustc.git/blob - src/tools/clippy/tests/ui/as_ptr_cast_mut.stderr
New upstream version 1.74.1+dfsg1
[rustc.git] / src / tools / clippy / tests / ui / as_ptr_cast_mut.stderr
1 error: casting the result of `as_ptr` to *mut u8
2 --> $DIR/as_ptr_cast_mut.rs:22:13
3 |
4 LL | let _ = string.as_ptr() as *mut u8;
5 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `string.as_mut_ptr()`
6 |
7 = note: `-D clippy::as-ptr-cast-mut` implied by `-D warnings`
8 = help: to override `-D warnings` add `#[allow(clippy::as_ptr_cast_mut)]`
9
10 error: casting the result of `as_ptr` to *mut i8
11 --> $DIR/as_ptr_cast_mut.rs:25:22
12 |
13 LL | let _: *mut i8 = string.as_ptr() as *mut _;
14 | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `string.as_mut_ptr()`
15
16 error: aborting due to 2 previous errors
17