Thread (2 messages) 2 messages, 2 authors, 2018-01-27

Re: [PATCH v3 1/3] read-cache: fix reading the shared index for other repos

From: Junio C Hamano <hidden>
Date: 2018-01-22 06:14:51

Possibly related (same subject, not in this thread)

Thomas Gummerer [off-list ref] writes:
On 01/19, Junio C Hamano wrote:
quoted
Thomas Gummerer [off-list ref] writes:
quoted
read_cache_from() defaults to using the gitdir of the_repository.  As it
is mostly a convenience macro, having to pass get_git_dir() for every
call seems overkill, and if necessary users can have more control by
using read_index_from().
This was a bit painful change, given that some changes in flight do
add new callsites to read_index_from() and they got the function
changed under their feet.
Sorry about that.  Is there any way to make such a change less painful
in the future?
One way is to do for read_index_from() what you did for the existing
users of read_cache_from().  Introduce a _new_ helper that will not
be known for any existing topics in flight, and use that to make the
existing API a thin wrapper around it.

I _think_ I got it right with evil merge, so unless this fix needs
to be delayed for extended period of time for whatever reason while
any more new callers of the function appears (which is unlikely), we
should be OK ;-)

Thanks.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help