Re: [PATCH 05/38] refs: create a base class "ref_store" for files_ref_store
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jun 10, 2016, 15:53 UTC
- Message-ID
- <xmqqziqtf3c3.fsf@gitster.mtv.corp.google.com>
- In-Reply-To
- <575A5BCF.20409@alum.mit.edu>
Michael Haggerty <mhagger@alum.mit.edu> writes:
Show 14 quoted lines
> On 06/09/2016 06:14 PM, Junio C Hamano wrote: >> Michael Haggerty <mhagger@alum.mit.edu> writes: >> >>>>> +static struct ref_store *main_ref_store = NULL; >>>>> + >>>>> +static struct ref_store *submodule_ref_stores = NULL; >>>> >>>> Let's let BSS take care of these initialization. >> [...] >> Lack of "= ..." is a clear-enough clue that the code wants these >> pointers initialized to NULL. >> [...] > > OK. While I'm at it I'll add docstrings for these variables.
Yeah, if you explain what they are used for, it would become obvious why their natural initial state is NULL.