Re: [PATCH 1/1] attr: enable attr pathspec magic for git-add and git-stash
On Sat, Nov 4, 2023 at 1:12 AM Junio C Hamano <gitster@pobox.com> wrote:
Show 9 quoted lines
> > + if ((magic & pathspec_magic[i].bit) && (pathspec_magic[i].mnemonic != '\0')) {
>
> Overly long, with a stylo.
>
> Here is what I ended up queuing.
>
> + for (int i = 0; i < ARRAY_SIZE(pathspec_magic); i++) {
> + if ((magic & pathspec_magic[i].bit) &&
> + (pathspec_magic[i].mnemonic)) {Nit: The no-value-added parentheses around
`pathspec_magic[i].mnemonic` can also be dropped.