X-Git-Url: https://svn.cri.ensmp.fr/git/linpy.git/blobdiff_plain/6120eb04e9422574814570d653e6ac19b057727f..f431ff9e62582cf7a4f12d17fb198c2fdaf47044:/pypol/isl.py?ds=sidebyside diff --git a/pypol/isl.py b/pypol/isl.py index 41716c1..f1e63dc 100644 --- a/pypol/isl.py +++ b/pypol/isl.py @@ -40,9 +40,10 @@ class Context: @property def _as_parameter_(self): return self._ic - + + #comment out so does not delete itself after being created #def __del__(self): - # libisl.isl_ctx_free(self) + # libisl.isl_ctx_free(self) def __eq__(self, other): if not isinstance(other, Context): @@ -119,8 +120,7 @@ class Value: numerator = libisl.isl_val_read_from_str(context, numerator) denominator = str(frac.denominator).encode() denominator = libisl.isl_val_read_from_str(context, denominator) - self._iv = libisl.isl_val_div(numerator, denominator) - print('in isl') + self._iv = libisl.isl_val_div(numerator, denominator) return self @@ -258,7 +258,7 @@ class Value: return bool(libisl.isl_val_is_infty(self) or libisl.isl_val_is_neginfty(self)) - def is_nan(self): + def is_nan(self): return bool(libisl.isl_val_is_nan(self)) def __str__(self):