X-Git-Url: http://git.tuebingen.mpg.de/?a=blobdiff_plain;f=yy%2Fmp.y;h=8df4f20ea04ebd2ea23b77ad77451e23e0022dbc;hb=HEAD;hp=06d76101daf42550ea192d1c963c32d5da6635d2;hpb=d511199b1f1f91cc53e31637bb801e5c2425829e;p=paraslash.git diff --git a/yy/mp.y b/yy/mp.y index 06d76101..8df4f20e 100644 --- a/yy/mp.y +++ b/yy/mp.y @@ -59,7 +59,7 @@ enum semantic_types { static struct mp_ast_node *ast_node_raw(int id) { - struct mp_ast_node *node = para_malloc(sizeof(struct mp_ast_node)); + struct mp_ast_node *node = alloc(sizeof(struct mp_ast_node)); node->id = id; return node; } @@ -76,7 +76,7 @@ static struct mp_ast_node *ast_node_new_unary(int id, struct mp_ast_node *child) { struct mp_ast_node *node = ast_node_raw(id); node->num_children = 1; - node->children = para_malloc(sizeof(struct mp_ast_node *)); + node->children = alloc(sizeof(struct mp_ast_node *)); node->children[0] = child; return node; } @@ -86,7 +86,7 @@ static struct mp_ast_node *ast_node_new_binary(int id, struct mp_ast_node *left, { struct mp_ast_node *node = ast_node_raw(id); node->num_children = 2; - node->children = para_malloc(2 * sizeof(struct mp_ast_node *)); + node->children = arr_alloc(2, sizeof(struct mp_ast_node *)); node->children[0] = left; node->children[1] = right; return node;