From: Paul Tan Date: Wed, 16 Mar 2016 12:56:09 GMT Subject: Re: [PATCH/RFC/GSoC 07/17] rebase-common: implement refresh_and_write_cache() Message-ID: In-Reply-To: On Tue, Mar 15, 2016 at 5:10 AM, Junio C Hamano wrote: > Paul Tan writes: > >> In the upcoming git-rebase to C rewrite, it is a common operation to >> refresh the index and write the resulting index. >> >> builtin/am.c already implements refresh_and_write_cache(), which is what >> we want. Move it to rebase-common.c, so that it can be shared with all >> the rebase backends, including git-am. > > Your rebase-am might be one of the rebase backends, but git-am is > not, so it is misleading to count it among "all the rebase > backends". > > I would think that a better home for refresh_and_write_index() is > right next to write_locked_index(), with #define in cache.h for > refresh_and_write_cache(), just like others. Okay, thanks for suggesting a better location. Regards, Paul