isl_dim_drop: always remove tuple name, even if number of dims to drop is zero
authorSven Verdoolaege <skimo@kotnet.org>
Mon, 2 Aug 2010 09:49:29 +0000 (11:49 +0200)
committerSven Verdoolaege <skimo@kotnet.org>
Mon, 2 Aug 2010 09:59:46 +0000 (11:59 +0200)
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
isl_dim.c

index 9cb3d7b..5a053f7 100644 (file)
--- a/isl_dim.c
+++ b/isl_dim.c
@@ -775,7 +775,7 @@ struct isl_dim *isl_dim_drop(struct isl_dim *dim, enum isl_dim_type type,
        if (!dim)
                return NULL;
 
-       if (n == 0)
+       if (n == 0 && !isl_dim_get_tuple_name(dim, type))
                return dim;
 
        isl_assert(dim->ctx, first + num <= n(dim, type), goto error);