summaryrefslogtreecommitdiff
path: root/src/tools/miri/tests/pass/ptr_offset.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/tools/miri/tests/pass/ptr_offset.rs')
-rw-r--r--src/tools/miri/tests/pass/ptr_offset.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tools/miri/tests/pass/ptr_offset.rs b/src/tools/miri/tests/pass/ptr_offset.rs
index 95eac8522fb..92b275b0032 100644
--- a/src/tools/miri/tests/pass/ptr_offset.rs
+++ b/src/tools/miri/tests/pass/ptr_offset.rs
@@ -63,7 +63,7 @@ fn ptr_arith_offset_overflow() {
let v = [1i16, 2];
let x = &mut ptr::null(); // going through memory as there are more sanity checks along that path
*x = v.as_ptr().wrapping_offset(1); // ptr to the 2nd element
- // Adding 2*isize::max and then 1 is like substracting 1
+ // Adding 2*isize::max and then 1 is like subtracting 1
*x = x.wrapping_offset(isize::MAX);
*x = x.wrapping_offset(isize::MAX);
*x = x.wrapping_offset(1);