summarylogtreecommitdiffstats
path: root/0002-Fix-invalid-operands-to-binary-expression.patch
blob: 10478f88e7ac6291312ce7ee5b2dfb93cc150cb1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
--- ppl/ppl_user.cc
+++ ppl/ppl_user.cc
@@ -320,7 +320,12 @@
       exact = false;
     }
     /* singleton */
-    else r.insert(Constraint(Variable(i)==temp));
+    else {
+      /* integerness check */
+      mpz_class temp2 = mpz_class(temp);
+      if (temp==temp2) r.insert(Constraint(Variable(i)==temp2));
+      else exact = false;
+    }
   }
   return exact;
 }