X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;ds=sidebyside;f=bucket.c;h=422c4224d46c9926f4bf330fc88bd32343da16a3;hb=b34c70d71aa20562c2d9ebab12866452a3d656bf;hp=17b7d02b824102900d39db615f083b4557cff067;hpb=c18a14dc560a2559262c1d5c4252fe80a73568f9;p=libfirm diff --git a/bucket.c b/bucket.c index 17b7d02b8..422c4224d 100644 --- a/bucket.c +++ b/bucket.c @@ -50,9 +50,9 @@ pbqp_edge *edge_bucket_pop(pbqp_edge_bucket *bucket) return edge; } -void node_bucket_clear(pbqp_node_bucket *bucket) +void node_bucket_shrink(pbqp_node_bucket *bucket, unsigned len) { - ARR_SHRINKLEN(*bucket, 0); + ARR_SHRINKLEN(*bucket, len); } int node_bucket_contains(pbqp_node_bucket bucket, pbqp_node *node) @@ -139,6 +139,6 @@ void node_bucket_deep_copy(pbqp *pbqp, pbqp_node_bucket *dst, pbqp_node_bucket s bucket_length = node_bucket_get_length(src); for (bucket_index = 0; bucket_index < bucket_length; ++bucket_index) { - node_bucket_insert(dst, pbqp_node_deep_copy(pbqp, src, src[bucket_index])); + node_bucket_insert(dst, pbqp_node_deep_copy(pbqp, *dst, src[bucket_index])); } }