Jonathan Wakely <jwak...@redhat.com> writes: > On Fri, 25 Oct 2024 at 12:54, Jakub Jelinek <ja...@redhat.com> wrote: >> >> On Fri, Oct 25, 2024 at 01:25:25PM +0200, Arsen Arsenović wrote: >> > Maybe we should go the other way around? Compressing eight spaces into >> > a tab leads to strange artifacts in diffs (where lines appear >> > misindented because some were aligned by tabs and some by spaces), and >> > nowadays editor authors seem to have forgotten tabs are eight spaces and >> > instead default to (or, worse, hard-code) four, obviously making the >> > codebase quite unreadable. We also don't get the benefit of being able >> > to adjust tabstop locally to our preferences when we use two-column >> > indentation, so I don't see an advantage to keeping 'indent-tabs-mode >> > (or equivalent in other editors) enabled. >> >> Editors which are worth a dime handle tabs fine, and I think using tabs is >> better. > > And if we put a .editorconfig file at the top level, then most decent > editors will be auto-configured as we want.
That won't help with wonky diffs. For example: + if (foo) + {} The indentation is correct here, but is wrong in the diff. This happens on every indent level 4N+3 to 4(N + 1) or back change. -- Arsen Arsenović
signature.asc
Description: PGP signature