Merge branch 'maint'
[platform/upstream/isl.git] / isl_map.c
index 6c34c22..cfb26fa 100644 (file)
--- a/isl_map.c
+++ b/isl_map.c
@@ -3813,7 +3813,8 @@ struct isl_set *isl_map_range(struct isl_map *map)
 
        if (!map)
                goto error;
-       if (isl_map_dim(map, isl_dim_in) == 0)
+       if (isl_map_dim(map, isl_dim_in) == 0 &&
+           !isl_dim_is_named_or_nested(map->dim, isl_dim_in))
                return (isl_set *)map;
 
        map = isl_map_cow(map);