4 ms·
I don't think 8 characters was ever an official standard, just a de facto one. The problem is that it's too large for most modern use cases. These days I find
by mark-r 5y ago
I don't think 8 characters was ever an official standard, just a de facto one. The problem is that it's too large for most modern use cases.
These days I find myself using smart editors that combine auto-indenting with tab-to-space conversion. You won't find a tab character in any of my files.
- kazinator 5y ago> it's too large for most modern use cases. That's just opinion, though; some lunatics think that 8 space indentation is just fine, and they control what goes into the Linux kernel. Basically, either you think 8 space indentation is fine, or else you regard 8 character tabs as not being suitable for the indentation use case (either you write off the tab entirely, or else subdue its size). It has nothing to do with modern; programmers revolted at 8 space indentation in 1980 also. Indentation of less than 8 is not a modern trend. Case study: V6 Unix, 1975. C compiler uses hard tabs for indentation: https://minnie.tuhs.org/cgi-bin/utree.pl?file=V6/usr/source/c/c00.c https://minnie.tuhs.org/cgi-bin/utree.pl?file=V6/usr/source/... (Was that viewed as 8 spaces though, when edited?) When we look at Yacc in the same release, we see the germination of the problem of mixed style. Part of the source uses two space indentation. Part of it uses hard tabs. Other conventions also differ: https://minnie.tuhs.org/cgi-bin/utree.pl?file=V6/usr/source/yacc/source/y1.c https://minnie.tuhs.org/cgi-bin/utree.pl?file=V6/usr/source/... Yikes! That's exactly the sort of thing that leads to tabs being banned. > You won't find a tab character in any of my files. I could almost say the same, except (1) rare accidents happen and (2) some of them are makefiles.