Re: [PATCH 05/24] dir.c: remove an implicit dependency on the_index in pathspec code

2018-08-13 Thread Duy Nguyen
On Mon, Aug 13, 2018 at 7:17 PM Brandon Williams wrote: > I'm just sorry I made it this messy :/ Take it with pride! I think all core devs can say "oh yes I've made big contributions. See there? I made that mess!" :D -- Duy

Re: [PATCH 05/24] dir.c: remove an implicit dependency on the_index in pathspec code

2018-08-13 Thread Brandon Williams
On 08/13, Nguyễn Thái Ngọc Duy wrote: > diff --git a/dir.c b/dir.c > index 29fbbd48c8..e25aed013b 100644 > --- a/dir.c > +++ b/dir.c > @@ -276,12 +276,13 @@ static int do_read_blob(const struct object_id *oid, > struct oid_stat *oid_stat, > #define DO_MATCH_DIRECTORY (1<<1) > #define DO_MATCH_SU

[PATCH 05/24] dir.c: remove an implicit dependency on the_index in pathspec code

2018-08-13 Thread Nguyễn Thái Ngọc Duy
Make the match_patchspec API and friends take an index_state instead of assuming the_index in dir.c. All external call sites are converted blindly to keep the patch simple and retain current behavior. Individual call sites may receive further updates to use the right index instead of the_index. Si