In perl.git, the branch mauke/overflow has been updated

<https://perl5.git.perl.org/perl.git/commitdiff/bd7061cd2e3b79521294f526a937701c04437e48?hp=22e28b23bddbfdf1e424aa94876180f5223bd758>

  discards  22e28b23bddbfdf1e424aa94876180f5223bd758 (commit)
  discards  355f5a6e2f0c359ea91e1867590a28959ab44b08 (commit)
  discards  74f6571c8beef8c6979587aa1fe4503972f48c23 (commit)
- Log -----------------------------------------------------------------
commit bd7061cd2e3b79521294f526a937701c04437e48
Author: Lukas Mai <l....@web.de>
Date:   Sun Oct 22 14:40:44 2017 +0200

    use __builtin_mul_overflow in pp_multiply

commit 1ca0866a62e4f9cbfc92fc7502335b593701f0d7
Author: Lukas Mai <l....@web.de>
Date:   Sun Oct 22 14:27:34 2017 +0200

    use __builtin_sub_overflow in pp_subtract

commit 90ba6e7724a7a6e4a83d986f278b2dc1c5928c67
Author: Lukas Mai <l....@web.de>
Date:   Sun Oct 22 13:43:03 2017 +0200

    use __builtin_add_overflow in pp_add

-----------------------------------------------------------------------

Summary of changes:
 op.c | 2 +-
 pp.c | 8 ++++----
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/op.c b/op.c
index 14764ad349..bcf1cba7c6 100644
--- a/op.c
+++ b/op.c
@@ -2585,8 +2585,8 @@ S_finalize_op(pTHX_ OP* o)
     case OP_CONST:
        if (cSVOPo->op_private & OPpCONST_STRICT)
            no_bareword_allowed(o);
-       /* FALLTHROUGH */
 #ifdef USE_ITHREADS
+        /* FALLTHROUGH */
     case OP_HINTSEVAL:
         op_relocate_sv(&cSVOPo->op_sv, &o->op_targ);
 #endif
diff --git a/pp.c b/pp.c
index 76b0ffe2cf..5d52683bba 100644
--- a/pp.c
+++ b/pp.c
@@ -1982,12 +1982,12 @@ PP(pp_subtract)
             const bool buvok = SvUOK(svr);
             if (auvok && buvok) {
                 const UV uvr = SvUVX(svr);
-                if (!__builtin_sub_overflow(uvl, uvr, &uresult)) {
-                    result_is_uv = TRUE;
+                if (!__builtin_sub_overflow(uvl, uvr, &iresult)) {
+                    result_is_uv = FALSE;
                     overflowed = FALSE;
                 }
-                else if (!__builtin_sub_overflow(uvl, uvr, &iresult)) {
-                    result_is_uv = FALSE;
+                else if (!__builtin_sub_overflow(uvl, uvr, &uresult)) {
+                    result_is_uv = TRUE;
                     overflowed = FALSE;
                 }
                 else {

-- 
Perl5 Master Repository

Reply via email to