2 * Copyright 2010 INRIA Saclay
4 * Use of this software is governed by the GNU LGPLv2.1 license
6 * Written by Sven Verdoolaege, INRIA Saclay - Ile-de-France,
7 * Parc Club Orsay Universite, ZAC des vignes, 4 rue Jacques Monod,
13 static void *isl_obj_map_copy(void *v)
15 return isl_map_copy((struct isl_map *)v);
18 static void isl_obj_map_free(void *v)
20 isl_map_free((struct isl_map *)v);
23 static __isl_give isl_printer *isl_obj_map_print(__isl_take isl_printer *p,
26 return isl_printer_print_map(p, (struct isl_map *)v);
29 static void *isl_obj_map_add(void *v1, void *v2)
31 return isl_map_union((struct isl_map *)v1, (struct isl_map *)v2);
34 struct isl_obj_vtable isl_obj_map_vtable = {
41 static void *isl_obj_set_copy(void *v)
43 return isl_set_copy((struct isl_set *)v);
46 static void isl_obj_set_free(void *v)
48 isl_set_free((struct isl_set *)v);
51 static __isl_give isl_printer *isl_obj_set_print(__isl_take isl_printer *p,
54 return isl_printer_print_set(p, (struct isl_set *)v);
57 static void *isl_obj_set_add(void *v1, void *v2)
59 return isl_set_union((struct isl_set *)v1, (struct isl_set *)v2);
62 struct isl_obj_vtable isl_obj_set_vtable = {
69 static void *isl_obj_none_copy(void *v)
74 static void isl_obj_none_free(void *v)
78 static __isl_give isl_printer *isl_obj_none_print(__isl_take isl_printer *p,
84 static void *isl_obj_none_add(void *v1, void *v2)
89 static struct isl_obj_vtable obj_none = {
95 isl_obj_type isl_obj_none = &obj_none;
97 static void *isl_obj_pw_qp_copy(void *v)
99 return isl_pw_qpolynomial_copy((struct isl_pw_qpolynomial *)v);
102 static void isl_obj_pw_qp_free(void *v)
104 isl_pw_qpolynomial_free((struct isl_pw_qpolynomial *)v);
107 static __isl_give isl_printer *isl_obj_pw_qp_print(__isl_take isl_printer *p,
110 return isl_printer_print_pw_qpolynomial(p,
111 (struct isl_pw_qpolynomial *)v);
114 static void *isl_obj_pw_qp_add(void *v1, void *v2)
116 return isl_pw_qpolynomial_add((struct isl_pw_qpolynomial *)v1,
117 (struct isl_pw_qpolynomial *)v2);
120 struct isl_obj_vtable isl_obj_pw_qpolynomial_vtable = {
127 static void *isl_obj_pw_qpf_copy(void *v)
129 return isl_pw_qpolynomial_fold_copy((struct isl_pw_qpolynomial_fold *)v);
132 static void isl_obj_pw_qpf_free(void *v)
134 isl_pw_qpolynomial_fold_free((struct isl_pw_qpolynomial_fold *)v);
137 static __isl_give isl_printer *isl_obj_pw_qpf_print(__isl_take isl_printer *p,
140 return isl_printer_print_pw_qpolynomial_fold(p,
141 (struct isl_pw_qpolynomial_fold *)v);
144 static void *isl_obj_pw_qpf_add(void *v1, void *v2)
146 return isl_pw_qpolynomial_fold_add((struct isl_pw_qpolynomial_fold *)v1,
147 (struct isl_pw_qpolynomial_fold *)v2);
150 struct isl_obj_vtable isl_obj_pw_qpolynomial_fold_vtable = {
153 isl_obj_pw_qpf_print,