From 3b4c362e3d3e649fc4689120edea24971e3eb38d Mon Sep 17 00:00:00 2001
From: nilfit <nils.fitinghoff@gmail.com>
Date: Wed, 28 Feb 2018 18:26:06 +0100
Subject: [PATCH] revert to old return value for intrinsic_overflowing

This fixes `tests/symbolic/slice` failing. It might be better to remove
the return value entirely since no one seems to use it.
---
 src/operator.rs | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/operator.rs b/src/operator.rs
index 538f412..6292095 100644
--- a/src/operator.rs
+++ b/src/operator.rs
@@ -60,7 +60,13 @@ impl<'a, 'tcx> EvalContext<'a, 'tcx> {
     ) -> EvalResult<'tcx, bool> {
         let (val, overflowed) = self.binop_with_overflow(op, left, right)?;
         self.write_primval(dest, val, dest_ty)?;
-        Ok(overflowed.to_bool()?)
+        if overflowed.is_concrete() {
+            Ok(overflowed.to_bool()?)
+        } else {
+            // keeps the old behavior of ignoring overflow for symbolic ops
+            // this works because the return value is never used
+            Ok(false)
+        }
     }
 }
 
-- 
GitLab