From bfcdffb90fdbd11e1fe998dce91fae7e944dfd4b Mon Sep 17 00:00:00 2001 From: Sven Verdoolaege Date: Sun, 2 Aug 2009 19:11:15 +0200 Subject: [PATCH] add isl_map_get_dim --- include/isl_map.h | 1 + isl_map.c | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/include/isl_map.h b/include/isl_map.h index b86efad..6533eb9 100644 --- a/include/isl_map.h +++ b/include/isl_map.h @@ -108,6 +108,7 @@ unsigned isl_map_n_param(const struct isl_map *map); unsigned isl_map_dim(const struct isl_map *map, enum isl_dim_type type); struct isl_dim *isl_basic_map_get_dim(struct isl_basic_map *bmap); +struct isl_dim *isl_map_get_dim(struct isl_map *map); struct isl_basic_map *isl_basic_map_alloc(struct isl_ctx *ctx, unsigned nparam, unsigned in, unsigned out, unsigned extra, diff --git a/isl_map.c b/isl_map.c index 0306875..b38030c 100644 --- a/isl_map.c +++ b/isl_map.c @@ -234,6 +234,13 @@ struct isl_dim *isl_basic_set_get_dim(struct isl_basic_set *bset) return isl_dim_copy(bset->dim); } +struct isl_dim *isl_map_get_dim(struct isl_map *map) +{ + if (!map) + return NULL; + return isl_dim_copy(map->dim); +} + struct isl_dim *isl_set_get_dim(struct isl_set *set) { if (!set) -- 2.7.4