projects
/
linpy.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
be3afc2
)
Check argument type in Domain.project()
author
Vivien Maisonneuve
<v.maisonneuve@gmail.com>
Tue, 19 Aug 2014 14:21:22 +0000
(16:21 +0200)
committer
Vivien Maisonneuve
<v.maisonneuve@gmail.com>
Tue, 19 Aug 2014 14:21:22 +0000
(16:21 +0200)
linpy/domains.py
patch
|
blob
|
history
diff --git
a/linpy/domains.py
b/linpy/domains.py
index
31b5c3f
..
7015252
100644
(file)
--- a/
linpy/domains.py
+++ b/
linpy/domains.py
@@
-278,6
+278,10
@@
class Domain(GeometricObject):
Project out the sequence of symbols given in arguments, and return the
resulting domain.
"""
+ symbols = list(symbols)
+ for symbol in symbols:
+ if not isinstance(symbol, Symbol):
+ raise TypeError('symbols must be Symbol instances')
islset = self._toislset(self.polyhedra, self.symbols)
n = 0
for index, symbol in reversed(list(enumerate(self.symbols))):