]> git.proxmox.com Git - rustc.git/blame - src/tools/clippy/tests/ui/ptr_offset_with_cast.stderr
New upstream version 1.52.1+dfsg1
[rustc.git] / src / tools / clippy / tests / ui / ptr_offset_with_cast.stderr
CommitLineData
f20569fa
XL
1error: use of `offset` with a `usize` casted to an `isize`
2 --> $DIR/ptr_offset_with_cast.rs:12:17
3 |
4LL | let _ = ptr.offset(offset_usize as isize);
5 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `ptr.add(offset_usize)`
6 |
7 = note: `-D clippy::ptr-offset-with-cast` implied by `-D warnings`
8
9error: use of `wrapping_offset` with a `usize` casted to an `isize`
10 --> $DIR/ptr_offset_with_cast.rs:16:17
11 |
12LL | let _ = ptr.wrapping_offset(offset_usize as isize);
13 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `ptr.wrapping_add(offset_usize)`
14
15error: aborting due to 2 previous errors
16