Re: [PATCH v10 5/9] ls-tree: optimize naming and handling of "return" in show_tree()
- From
Teng Long <dyroneteng@gmail.com>
- Date
- Jan 14, 2022, 07:59 UTC
- Message-ID
- <CADMgQSQ3oWAbDMK73hEwZKJHhO_k8CuJdC2TNWW0+kv1TzYfRQ@mail.gmail.com>
- In-Reply-To
- <220113.861r1cxgxx.gmgdl@evledraar.gmail.com>
On Thu, Jan 13, 2022 at 2:55 PM Ævar Arnfjörð Bjarmason <avarab@gmail.com> wrote:
> Re the $subject: Is "optimize naming" here just referring to the > s/retval/recurse/g?
Yes.
> Personally I think just a s/retval/ret/g here would make more senes if > we're doing any change at all, and in either case having this variable > re-rename split up as its own commit would make the proposed control > flow changes clearer.
Do you mean that I can split the current one into two commits, one does the renaming work and another one does the left work?
If so, I will do this in the next patch.
Show 8 quoted lines
> > This new function is a re-invention of the object_type() utility in > cache.h, and isn't needed. I.e.... > > ...just drop it and do this: > > - enum object_type type = get_type(mode); > + enum object_type type = object_type(mode);
You are absolutely correct. I will replace get_type() to object_type() in the next patch.