+ casts = get_type_cast_array(tp);
+ ARR_APP1(ir_node *, casts, n);
+ set_type_cast_array(tp, casts);
+}
+
+void set_type_cast(const ir_type *tp, int pos, ir_node *n) {
+ ir_node **casts;
+
+ assert(0 <= pos && pos < get_type_n_casts(tp));
+ assert(n && is_ir_node(n));
+
+ casts = get_type_cast_array(tp);
+ casts[pos] = n;
+}
+
+/*------------------------------------------------------------------*/
+
+int get_type_n_pointertypes_to(const ir_type *tp) {
+ ir_type ** pts;
+
+ assert(tp && is_type(tp));
+
+ pts = get_type_pointertype_array(tp);
+ return ARR_LEN(pts);
+}
+
+ir_type *get_type_pointertype_to(const ir_type *tp, int pos) {
+ ir_type ** pts;
+
+ assert(0 <= pos && pos < get_type_n_pointertypes_to(tp));
+
+ pts = get_type_pointertype_array(tp);
+ return pts[pos];
+}
+
+void add_type_pointertype_to(const ir_type *tp, ir_type *ptp) {
+ ir_type ** pts;
+
+ assert(tp && is_type(tp));
+ assert(ptp && is_Pointer_type(ptp));
+
+ pts = get_type_pointertype_array(tp);
+ ARR_APP1(ir_node *, pts, ptp);
+ set_type_pointertype_array(tp, pts);
+}
+
+void set_type_pointertype_to(const ir_type *tp, int pos, ir_type *ptp) {
+ ir_type ** pts;
+
+ assert(0 <= pos && pos < get_type_n_pointertypes_to(tp));
+ assert(ptp && is_Pointer_type(ptp));
+
+ pts = get_type_pointertype_array(tp);
+ pts[pos] = ptp;
+}
+
+
+/*------------------------------------------------------------------*/
+
+int get_type_n_arraytypes_of(const ir_type *tp) {
+ ir_type ** pts;
+
+ assert(tp && is_type(tp));
+
+ pts = get_type_arraytype_array(tp);
+ return ARR_LEN(pts);
+}
+
+ir_type *get_type_arraytype_of(const ir_type *tp, int pos) {
+ ir_type ** pts;
+
+ assert(0 <= pos && pos < get_type_n_arraytypes_of(tp));
+
+ pts = get_type_arraytype_array(tp);
+ return pts[pos];
+}
+
+void add_type_arraytype_of(const ir_type *tp, ir_type *atp) {
+ ir_type ** pts;
+
+ assert(tp && is_type(tp));
+ assert(atp && is_Array_type(atp));
+
+ pts = get_type_arraytype_array(tp);
+ ARR_APP1(ir_node *, pts, atp);
+ set_type_arraytype_array(tp, pts);
+}
+
+void set_type_arraytype_of(const ir_type *tp, int pos, ir_type *atp) {
+ ir_type ** pts;
+
+ assert(0 <= pos && pos < get_type_n_arraytypes_of(tp));
+ assert(atp && is_Array_type(atp));
+
+ pts = get_type_arraytype_array(tp);
+ pts[pos] = atp;