make firm compilable with a c++ compiler
[libfirm] / ir / tr / compound_path.c
index 9d7c19d..583dff0 100644 (file)
@@ -43,7 +43,7 @@ compound_graph_path *new_compound_graph_path(ir_type *tp, int length)
        assert(is_compound_type(tp) || is_Array_type(tp));
        assert(length > 0);
 
-       res = xmalloc(sizeof(*res) + (length-1) * sizeof(res->list[0]));
+       res = (compound_graph_path*)xmalloc(sizeof(*res) + (length-1) * sizeof(res->list[0]));
        memset(res, 0, sizeof(*res) + (length-1) * sizeof(res->list[0]));
        res->kind = k_ir_compound_graph_path;
        res->tp   = tp;
@@ -292,7 +292,7 @@ void set_compound_ent_value(ir_entity *ent, ir_node *val, ir_entity *member,
        set_compound_ent_value_w_path(ent, val, path, pos);
 }
 
-void set_array_entity_values(ir_entity *ent, tarval **values, int num_vals)
+void set_array_entity_values(ir_entity *ent, ir_tarval **values, int num_vals)
 {
        int i;
        ir_type  *arrtp = get_entity_type(ent);