summaryrefslogtreecommitdiff
path: root/pp.c
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2021-03-15 21:01:47 -0600
committerKarl Williamson <khw@cpan.org>2021-03-29 08:53:34 -0600
commit4e82c85b1c9c9b30253b8624470da6f20a6c0604 (patch)
treedfecf8b7e83c6ca2c6d585633df848797a435e11 /pp.c
parente7ba8cfdf9fb07ab6669c58b380241e480711c01 (diff)
downloadperl-4e82c85b1c9c9b30253b8624470da6f20a6c0604.tar.gz
Fix broken left shift of IV_MIN under 'use integer'
This fixes GH 18639 When I wrote this code, I conflated casting and complementing.
Diffstat (limited to 'pp.c')
-rw-r--r--pp.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/pp.c b/pp.c
index d365afea4c..baf0777a47 100644
--- a/pp.c
+++ b/pp.c
@@ -2007,9 +2007,6 @@ static IV S_iv_shift(IV iv, int shift, bool left)
* 18446744073709551552
* */
if (left) {
- if (iv == IV_MIN) { /* Casting this to a UV is undefined behavior */
- return 0;
- }
return (IV) (((UV) iv) << shift);
}