From 0dba74e5eb85b09a85f0a986c3fbc6b5fcacceac Mon Sep 17 00:00:00 2001 From: Vivien Maisonneuve Date: Tue, 9 Sep 2014 11:13:23 +0200 Subject: [PATCH] Polyhedron() constructor can return Empty or Universe --- linpy/polyhedra.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/linpy/polyhedra.py b/linpy/polyhedra.py index ead9b83..820b014 100644 --- a/linpy/polyhedra.py +++ b/linpy/polyhedra.py @@ -222,6 +222,10 @@ class Polyhedron(Domain): @classmethod def _fromislbasicset(cls, islbset, symbols): + if bool(libisl.isl_basic_set_is_empty(islbset)): + return Empty + if bool(libisl.isl_basic_set_is_universe(islbset)): + return Universe islconstraints = islhelper.isl_basic_set_constraints(islbset) equalities = [] inequalities = [] -- 2.20.1