projects
/
linpy.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
62fbaa7
)
Move isl version test in Domain.vertices outside
author
Vivien Maisonneuve
<v.maisonneuve@gmail.com>
Tue, 19 Aug 2014 14:41:39 +0000
(16:41 +0200)
committer
Vivien Maisonneuve
<v.maisonneuve@gmail.com>
Tue, 19 Aug 2014 14:41:47 +0000
(16:41 +0200)
linpy/domains.py
patch
|
blob
|
history
diff --git
a/linpy/domains.py
b/linpy/domains.py
index
9fdc7d5
..
4b3e982
100644
(file)
--- a/
linpy/domains.py
+++ b/
linpy/domains.py
@@
-391,7
+391,10
@@
class Domain(GeometricObject):
islset = libisl.isl_set_lexmax(islset)
return self._fromislset(islset, self.symbols)
islset = libisl.isl_set_lexmax(islset)
return self._fromislset(islset, self.symbols)
- _RE_COORDINATE = re.compile(r'\((?P<num>\-?\d+)\)(/(?P<den>\d+))?')
+ if islhelper.isl_version >= '0.13':
+ _RE_COORDINATE = re.compile(r'\((?P<num>\-?\d+)\)(/(?P<den>\d+))?')
+ else:
+ _RE_COORDINATE = None
def vertices(self):
"""
def vertices(self):
"""
@@
-409,7
+412,7
@@
class Domain(GeometricObject):
for vertex in vertices:
expr = libisl.isl_vertex_get_expr(vertex)
coordinates = []
for vertex in vertices:
expr = libisl.isl_vertex_get_expr(vertex)
coordinates = []
- if
islhelper.isl_version < '0.13'
:
+ if
self._RE_COORDINATE is None
:
constraints = islhelper.isl_basic_set_constraints(expr)
for constraint in constraints:
constant = libisl.isl_constraint_get_constant_val(constraint)
constraints = islhelper.isl_basic_set_constraints(expr)
for constraint in constraints:
constant = libisl.isl_constraint_get_constant_val(constraint)