From 38f1a592e80176863a68a2bf305f4dfd6e1999cb Mon Sep 17 00:00:00 2001 From: Sven Verdoolaege Date: Thu, 16 Aug 2018 18:07:04 +0200 Subject: [PATCH] isl_qpolynomial_var_on_domain: impose stricter check for set space The original test only checks for the absence of input dimensions, but ever since isl-0.07-142-g9043b59e4d (explicitly differentiate between spaces of maps, sets and parameter sets, Thu Aug 25 19:21:05 2011 +0200), set spaces are marked explicitly and the input space needs to be marked as such. Signed-off-by: Sven Verdoolaege --- isl_polynomial.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/isl_polynomial.c b/isl_polynomial.c index a130ba6e..d5609852 100644 --- a/isl_polynomial.c +++ b/isl_polynomial.c @@ -2098,11 +2098,8 @@ __isl_give isl_qpolynomial *isl_qpolynomial_var_pow_on_domain( __isl_give isl_qpolynomial *isl_qpolynomial_var_on_domain( __isl_take isl_space *domain, enum isl_dim_type type, unsigned pos) { - if (!domain) - return NULL; - - isl_assert(domain->ctx, - isl_space_dim(domain, isl_dim_in) == 0, goto error); + if (isl_space_check_is_set(domain ) < 0) + goto error; isl_assert(domain->ctx, pos < isl_space_dim(domain, type), goto error); if (type == isl_dim_set) -- 2.11.4.GIT