add isl_val_list
authorSven Verdoolaege <skimo@kotnet.org>
Tue, 30 Apr 2013 04:53:17 +0000 (06:53 +0200)
committerSven Verdoolaege <skimo@kotnet.org>
Tue, 28 May 2013 16:15:04 +0000 (18:15 +0200)
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
doc/user.pod
include/isl/val.h
isl_val.c
isl_val_private.h

index 94a0fd6..30b0120 100644 (file)
@@ -3245,7 +3245,7 @@ returning a basic set or relation.
 =head2 Lists
 
 Lists are defined over several element types, including
-C<isl_id>, C<isl_aff>, C<isl_pw_aff>, C<isl_constraint>,
+C<isl_val>, C<isl_id>, C<isl_aff>, C<isl_pw_aff>, C<isl_constraint>,
 C<isl_basic_set>, C<isl_set>, C<isl_ast_expr> and C<isl_ast_node>.
 Here we take lists of C<isl_set>s as an example.
 Lists can be created, copied, modified and freed using the following functions.
index 8c3a6f0..161602a 100644 (file)
@@ -2,6 +2,7 @@
 #define ISL_VAL_H
 
 #include <isl/ctx.h>
+#include <isl/list.h>
 #include <isl/printer.h>
 
 #if defined(__cplusplus)
@@ -11,6 +12,8 @@ extern "C" {
 struct isl_val;
 typedef struct isl_val isl_val;
 
+ISL_DECLARE_LIST(val)
+
 __isl_give isl_val *isl_val_zero(isl_ctx *ctx);
 __isl_give isl_val *isl_val_one(isl_ctx *ctx);
 __isl_give isl_val *isl_val_nan(isl_ctx *ctx);
index ff091c3..fb4b857 100644 (file)
--- a/isl_val.c
+++ b/isl_val.c
 #include <isl_ctx_private.h>
 #include <isl_val_private.h>
 
+#undef BASE
+#define BASE val
+
+#include <isl_list_templ.c>
+
 /* Allocate an isl_val object with indeterminate value.
  */
 __isl_give isl_val *isl_val_alloc(isl_ctx *ctx)
index 92d484c..8f2ce83 100644 (file)
@@ -20,6 +20,11 @@ struct isl_val {
        isl_int d;
 };
 
+#undef EL
+#define EL isl_val
+
+#include <isl_list_templ.h>
+
 __isl_give isl_val *isl_val_alloc(isl_ctx *ctx);
 __isl_give isl_val *isl_val_normalize(__isl_take isl_val *v);
 __isl_give isl_val *isl_val_int_from_isl_int(isl_ctx *ctx, isl_int n);