Re: [RFC 16/17] object_array_entry: copy name before storing in name field

2013-05-20 Thread Michael Haggerty
On 05/20/2013 06:44 PM, Jeff King wrote: > On Mon, May 20, 2013 at 04:42:38PM +0200, Michael Haggerty wrote: > * Many callers store the empty string ("") as the name; for example, most of the entries created during a run of rev-list have "" as their name. This means that lots o

Re: [RFC 16/17] object_array_entry: copy name before storing in name field

2013-05-20 Thread Jeff King
On Mon, May 20, 2013 at 04:42:38PM +0200, Michael Haggerty wrote: > >> * Many callers store the empty string ("") as the name; for example, > >> most of the entries created during a run of rev-list have "" as > >> their name. This means that lots of needless copies of "" are being > >> made

Re: [RFC 16/17] object_array_entry: copy name before storing in name field

2013-05-20 Thread Michael Haggerty
On 05/20/2013 12:33 PM, Johan Herland wrote: > On Sun, May 19, 2013 at 10:27 PM, Michael Haggerty > wrote: >> This is the culmination of the last few commits. Since some callers >> want to store refnames in the name field of object_array elements, but >> we don't want those callers to assume tha

Re: [RFC 16/17] object_array_entry: copy name before storing in name field

2013-05-20 Thread Johan Herland
On Sun, May 19, 2013 at 10:27 PM, Michael Haggerty wrote: > This is the culmination of the last few commits. Since some callers > want to store refnames in the name field of object_array elements, but > we don't want those callers to assume that the refnames that they got > from for_each_ref() ha