diff options
| author | Ralf Jung <post@ralfj.de> | 2022-11-20 09:58:29 +0100 |
|---|---|---|
| committer | Ralf Jung <post@ralfj.de> | 2022-11-20 09:58:29 +0100 |
| commit | 2bb28c174bdc47ec5cb7e734ed925d1f37c4000b (patch) | |
| tree | 565bc5443976b0d6c14c17053720f9d0cf069688 | |
| parent | 2ed65da15279d25e8b8b91d60162930ab48f16f6 (diff) | |
| download | rust-2bb28c174bdc47ec5cb7e734ed925d1f37c4000b.tar.gz rust-2bb28c174bdc47ec5cb7e734ed925d1f37c4000b.zip | |
avoid non-strict-provenance casts in libcore tests
| -rw-r--r-- | library/core/tests/ptr.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/library/core/tests/ptr.rs b/library/core/tests/ptr.rs index 390148550a4..90bc8351080 100644 --- a/library/core/tests/ptr.rs +++ b/library/core/tests/ptr.rs @@ -677,7 +677,7 @@ fn align_offset_issue_103361() { #[cfg(target_pointer_width = "16")] const SIZE: usize = 1 << 13; struct HugeSize([u8; SIZE - 1]); - let _ = (SIZE as *const HugeSize).align_offset(SIZE); + let _ = ptr::invalid::<HugeSize>(SIZE).align_offset(SIZE); } #[test] |
