Re: [PATCH 12/13] strvec: implement swapping two strvecs
On 2024-03-27 at 21:22:17, Junio C Hamano wrote:
Show 16 quoted lines
> Patrick Steinhardt <ps@pks.im> writes:
>
> >> +
> >> +void strvec_swap(struct strvec *a, struct strvec *b)
> >> +{
> >> + struct strvec t = *a;
> >> + *a = *b;
> >> + *b = t;
> >> +}
> >
> > Isn't this equivalent to `SWAP(*a, *b)`?
>
> Yes. "make coccicheck" does flag this one.
>
> Let's drop this step, and tweak the 13/13 patch to make its sole
> caller directly use SWAP() instead, perhaps like so:Great, I'll include that in a reroll, likely this weekend.
--
brian m. carlson (they/them or he/him)
Toronto, Ontario, CA