Re: [PATCH 2/2] maint: re-indent C source code.
James Youngman <[email protected]> Mon, 13 Jul 2026 00:00:10 +0100
| Newsgroups | gmane.comp.gnu.findutils.patches,gmane.comp.gnu.findutils.bugs |
|---|---|
| Message-ID | <CAGwX765+rFjDX9xi5yAiX-fD9BSTPuo_cbsJMQj3xzkvWqfDjA@mail.gmail.com> |
On Sun, Jul 12, 2026 at 8:06=E2=80=AFPM Collin Funk <[email protected]= > wrote: > Cool, I always disliked the mix of tabs and spaces that lots of (mostly) > older GNU code has. I think it is because both emacs and indent do it by > default. > > My preference is not to use indent or similar tools (e.g., clang-format) > because it is a hassle if all contributors do not have the same version > available, since their outputs aren't stable in my experience. Indeed. Early in my career I collaborated with a colleague who always set up his terminal with a non-standard tab-width of 4 because he wanted to use an indentation-level of 4 for nested braces. So I learned pretty early on that tabs are a frequent source of minor irritation. Winnie was right. Colin's example: [before indent] > struct timespec ts =3D { .tm_sec =3D 0, .tm_nsec =3D 0 }; [after indent] > struct timespec ts =3D {.tm_sec =3D 0,.tm_nsec =3D 0 }; > > Just figured I would bring this up for your consideration. Not trying to > demand you disable it or anything like that. :) Actually I have no particular beliefs on this. But I don't think this is configurable in GNU indent (unless -sar does what you want). GNU indent what we get in gnulib's maint.mk by default. But if GNU indent allowed this to be configurable, I would not object to a change. Bernhard, do you have a preference? James.