Rename Constant into Rational
[linpy.git] / pypol / polyhedra.py
index 6ef7cc1..fa2a5c6 100644 (file)
@@ -4,7 +4,7 @@ import numbers
 from . import islhelper
 
 from .islhelper import mainctx, libisl
-from .linexprs import Expression, Constant
+from .linexprs import Expression, Rational
 from .domains import Domain
 
 
@@ -219,12 +219,12 @@ def _polymorphic(func):
     @functools.wraps(func)
     def wrapper(left, right):
         if isinstance(left, numbers.Rational):
-            left = Constant(left)
+            left = Rational(left)
         elif not isinstance(left, Expression):
             raise TypeError('left must be a a rational number '
                 'or a linear expression')
         if isinstance(right, numbers.Rational):
-            right = Constant(right)
+            right = Rational(right)
         elif not isinstance(right, Expression):
             raise TypeError('right must be a a rational number '
                 'or a linear expression')