about summary refs log tree commit diff
path: root/compiler/rustc_const_eval/messages.ftl
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2024-08-01 14:38:58 +0200
committerRalf Jung <post@ralfj.de>2024-08-01 14:38:58 +0200
commitdb1652e07b7e6f81692795e7cb3b8c02798b1756 (patch)
tree435196003ac45963e802611698552941ac293754 /compiler/rustc_const_eval/messages.ftl
parent5d5c97aad7cd2803b6dbecdd34293616065dc6b2 (diff)
downloadrust-db1652e07b7e6f81692795e7cb3b8c02798b1756.tar.gz
rust-db1652e07b7e6f81692795e7cb3b8c02798b1756.zip
fix the way we detect overflow for inbounds arithmetic (and tweak the error message)
Diffstat (limited to 'compiler/rustc_const_eval/messages.ftl')
-rw-r--r--compiler/rustc_const_eval/messages.ftl2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_const_eval/messages.ftl b/compiler/rustc_const_eval/messages.ftl
index e02d6ebb183..94cdd021d8d 100644
--- a/compiler/rustc_const_eval/messages.ftl
+++ b/compiler/rustc_const_eval/messages.ftl
@@ -277,7 +277,7 @@ const_eval_partial_pointer_copy =
 const_eval_partial_pointer_overwrite =
     unable to overwrite parts of a pointer in memory at {$ptr}
 const_eval_pointer_arithmetic_overflow =
-    overflowing in-bounds pointer arithmetic
+    overflowing pointer arithmetic: the total offset in bytes does not fit in an `isize`
 const_eval_pointer_arithmetic_test = out-of-bounds pointer arithmetic
 const_eval_pointer_out_of_bounds =
     {$bad_pointer_message}: {const_eval_expected_inbounds_pointer}, but got {$pointer} {$ptr_offset_is_neg ->