9 ms·
Nobody talks about the real reason to use Tabs over Spaces
- the_seraphim 7y agoWell, that answers that question then eh...
- sureaboutthis 7y agoThis is one of the stupidest reasons I have ever read. Tabs versus spaces has been ongoing for decades--long before anyone ever gave a hoot about accesssability. But it comes from the minds at reddit and nothing more should be expected.
- AlEinstein 7y agoThere is no logical coherence to this statement. Just because there have been proponents of both sides of a debate for many years doesn't mean that a new argument is invalid.
- deleted 7y ago[deleted]
- sureaboutthis 7y agoNot every new argument, decades later, is valid either and this is a dim witted one. As made up on the spot as they come.
- AlEinstein 7y agoBut you still haven't said what's dim witted about it.
- sureaboutthis 7y agoI did.
- afiori 7y agoI believe you refer to the "real" in the title as meaning "historically correct". If that is the case it is a silly argument. Real can also mean "having relevant effect in practice"
- dang 7y agoWe've banned this account for repeatedly violating the site guidelines ignoring our request to stop. I held off as long as I could, but this is egregious. https://news.ycombinator.com/newsguidelines.html https://news.ycombinator.com/newsguidelines.html
- dkersten 7y agoSo, just because you’re not personally affected, it’s a non-issue? Just because people argued about it before other people’s heeds were taken into account, it’s a non-issue?
- sureaboutthis 7y agoQuit making up things I never said.
- dkersten 7y agoThe poster said that the reason to prefer tabs is because his visually impaired coworkers find spaces difficult. You said “this is one of the stupidest reasons I’ve ever read”. What I asked you is in direct response to your statement as your statement (calling the reason given by people who are actually affected stupid) makes it very much sound like you don’t care about their plight and I am asking if they’re wrong because you aren’t affected. My questions are for sure loaded, but I’m asking you, not putting words in your month.
- sureaboutthis 7y agoThe post is about "the real reason" and the real reason was never for impaired workers and it is not "the real reason" in almost all cases! Quit using the minority to represent the majority!
- dkersten 7y agoMaybe not "the" real reason, but it is a real reason. > Quit using the minority to represent the majority! Where did I do that, exactly? In my interaction with you, I didn't even say whether or not I agree with TFA, I only asked if its a non-issue because 1) you're not affected and 2) people have argued about it for a long time. Yes, yes, my questions were loaded and probably assumed too much, but given the tone of your comment (calling it the stupidest reason, even though its clearly a very valid concern for the people affected), I feel I was justified in doing so. So, let me ask you two different questions then: 1. Do you agree that one should use tabs over spaces if there are visually impaired people on your team, who have difficulty with spaces? 2. Given that you can't know who may have to touch your code in the future, why do you think that its not worth doing so preemptively? Obviously, a valid answer to 2. is "no, because the likelihood that it will matter is low", which is true, but given that the cost of using tabs over spaces is super low, but the cost of using spaces for those it affects is high (sure, you can convert, but see elsewhere in these comments, its not perfect), I feel like its an easy choice. Obviously you disagree, which is fine and not the reason I'm arguing with you.
- ablomen 7y agoI totally agree, as a dyslexic big pieces of text look like a garbled mess. I need > 2 spaces to be able to navigate a file with code with any speed. Tabs for indentation, spaces for alignment looks to me like the best of both worlds.
- C1sc0cat 7y agoThe problem I have (also a dyslexic) with tabs vs spaces is you cant (normaly) see tabs. The old school 80 column fixed layouts like Fortran had did have its advantages.
- enriquto 7y ago> The problem I have (also a dyslexic) with tabs vs spaces is you cant (normaly) see tabs. There is probably no editor program in your computer right now that is not able to display tabs visually.
- C1sc0cat 7y agoYes I know but I am not working with with those fugly show white space settings turned on. Like one of the previous commentators I am a dyslexic and I find displayed tabs CR etc very visually distracting
- carlmr 7y agoVSCode doesn't display the CR and with the boundary setting doesn't show whitespace when it's a single space between words.
- syshum 7y agoThere is no debate... every rational person knows tabs are better.
- toyg 7y agoI used to be a “tab person” when I started using python in 2001 - after all, it makes more logical sense and it saves bytes, what’s not to like? And then the world duly standardized on 4-spaces-per-indent. So I’ve long given up and just gone with the flow. Unless big projects switch to tabs in a coordinated manner, to make a big statement, this matter is unlikely to ever be reevaluated.
- yitchelle 7y agoWould be interesting to see a table of spaces per indent vs language or Project. I know the Linux kernel has an 8 spaces requirement. Code has been known to be rejected based on this violation.
- silon42 7y agoLinux kernel has 1 tab, which many/most would map to 8 (including me). Mapping to 8 has (and not 2 and 4) becomes relevant if you have line size limits.
- C1sc0cat 7y agoThat struck me as odd surely 8 is the norm - a holdover from typewriters
- dTal 7y agoI'm not sure that indentation should count towards line size limits at all, or at least not more than 1 character per indent. If it doesn't fit on your screen, you can change your tab width until it does.
- raverbashing 7y agoLinux kernel is 1 tab Golang also mandates tabs I think
- timclark 7y agoFrom memory go fmt will use both tabs and spaces when formatting but it uses tabs for indentation from the left margin and uses spaces for some alignment of variables - so it doesn't introduce any crazy interleaving of tabs and spaces which I like.
- mojuba 7y agoThat's a very good argument, but I have another one, also often dismissed: if you navigate using your keyboard's arrow keys (which can be more productive than mouse/trackpad) then jumping over tabs to reach text is just way faster. Spaces kind of force you to use your mouse more.
- mysterydip 7y agoI tend to use ctrl+left or right to skip to the next non-whitespace character (depending on your editor).
- mojuba 7y agoYes, editors usually provide a function for that. But a lot of the times, say you go down where code is indented one level deeper and all you need is to just go right once. That's always faster than any combination of keys your editor can provide.
- viraptor 7y agoMany editors skip the whole indentation level when using arrows. The actual encoding is irrelevant for them. Atom calls this setting "atomic soft tabs", I believe.
- xiwenc 7y agoAssuming you're not using some very basic text editor; good ones have skip word. For instance 'w' in vim, or 'ctrl + right' in vscode.
- master-litty 7y ago[redacting]
- bhaak 7y agoEyes don't get worse from use. If you strain your eyes because of the lighting conditons, your eyes get fatigued but it has no detrimental long time effects.
- master-litty 7y agoThank you, I seem to be severely misinformed. Redacting my original thoughts now. I have very poor vision and have been told by two different optomotrists that for me, personally, my vision will worsen as I strain my eyes. I never thought to wonder if this was different for anyone else -- One of those things it seems.
- wrong_variable 7y agoI do not have eye strain. I have astigmatism - something that is heredity. I use tabs. My spherical power is normal. Are you saying anyone without perfect vision should quit coding ?
- master-litty 7y agoNot at all. I was careful with my phrasing to indicate that but perhaps missed the main thought -- Perhaps a visual tool isn't the most effective nor pleasurable one for a severely visually impaired individual. Not because of any "burden" they create on others (e.g. using tabs which isn't a real burden at all) or an elitist attitude (e.g. they shouldn't code), but because of the burden I imagine sight is to them. I wear glasses over my contacts simultaneously to work at a screen effectively -- I've been told by my optomotrists that work at the screen will continue to make my vision worse, but evidently I'm not too familiar with the correct terminology for my own impairments nor for others (and whether they always worsen). A fundamental misunderstanding on my part.
- 7y ago
- billpg 7y agoI kind of feel that source code needs to take a tip from HTML and apply a style-sheet. Have editors parse the code and display according to the user's preferences.
- kranner 7y agoExactly. Maybe a browser extension to pretty-print spaces to tabs, or sites like Github/SO can offer a built-in option.
- billpg 7y agoI'd go even farther than that. Prefer {}, BEGIN/END or indented code? Prefer && and || or AND and OR? Prefer infix a+b+c or LISP style +(a,b,c)? Pick one and the editor will show and edit code that way. The underlying code files remain unchanged.
- swerner 7y agoAbsolutely. Not just tabs vs spaces, but also camel case vs underscore, line length, etc.
- robin_reala 7y agoTalking of which, here’s the little-used CSS rule tab-size: https://developer.mozilla.org/en-US/docs/Web/CSS/tab-size https://developer.mozilla.org/en-US/docs/Web/CSS/tab-size
- deleted 7y ago[deleted]
- coldtea 7y ago>one of them uses tab-width 1 because he uses such a gigantic font-size But if they use a "giganting font-size" to see the letters, spaces would still be proportionally gigantic. Why would they need to have custom indent size, since everything will play along with their font-size choice? That is, why someone might want to use gigantic fonts but constraint that gigantic-ness to the actual letters, and not the indents too? Isn't it equally important to see indentation clearly?
- fmoralesc 7y agoI'm guessing when your fonts are sufficiently gigantic indents of 1 char are more than enough to see the indentation clearly (try it out). Actually, less than 1 char might be good enough or even better.
- viraptor 7y agoI don't know how bad the eyesight of the mentioned person was, but you may not be thinking gigantic enough. I know of people who zoom into the text to the level where maybe two-three words are visible in a line. (not all the time, but at the extreme, when reading something specific) By injecting more indent, you have to scroll a lot horizontally, or potentially miss an extra word from view if you get 2-3 extra levels of indent. If your space is at a few cm wide, it may be enough indication. Then, there are also ways of colouring indents for better visibility. (not sure if that's used for accessibility though, but it does make large indents not as important for me)
- the_other 7y agoWhy challenge someone's self-selected, battle-won access solutions before you spend time with them understanding their choices?
- prepend 7y agoFor me the challenge is part of understanding choices. I don’t think of challenge as conflict, but as a way of looking at different possibilities to learn more about why.
- colordrops 7y agoMost decent editors can operate with tabs or spaces functioning identically, so this is mostly a moot point. With that in mind, spaces are easier to display in tools that don't handle tabs well, so using spaces is still the right approach in my estimation.
- dkersten 7y agoAnd yet these visually impaired people apparently pleaded with the OP not to take away their tabs. Almost every program to edit text has a tab stop setting, but only the most advanced dev tools allow you the same control over spaces. Anecdotally, I’ve been struggling to get emacs to indent a certain language correctly for me (I want it to use two spaces in a place where it only uses one, I’m not really an emacs person so figuring out how to fix it is too much effort for me), if I were to switch to tabs, that would be easy: just set the tab width and be done with it. I don’t have any experience with screen readers, but it would seem to me that they should have an easier time with tabs too.
- prepend 7y agoI wish the story had described the editors used by the two visually impaired coders. It seems odd that they are using an environment that doesn’t up/down convert easily. It mentioned they were forced to do this like it was a manual process. Free IDEs like VScode do this, and it works with screen readers. Although from the description of their screens with large fonts and wide resolutions, I don’t think they were using screen readers. Since the article is missing this bit, I can’t help that fear that all three would have benefited from knowing how to config editors to get around this problem.
- scrollaway 7y agoNo IDE I know of can reliably convert spaces to tabs in a display mode only (= without actually causing code changes).
- dkersten 7y ago
- undecisive 7y agoThat is a pretty good point. As a rubyist, I always use and advocate two spaces - but if I ever find myself on a team with visual impairments, I'll be sure to ask whether tabs would be useful to the team. I'm a big believer that Team-level consistency is far more important than Universe-level consistency, and silver bullets kill. That said, I'm intrigued - surely this must be a solved problem at this point? Anybody aware of any good text editors / editor plugins that allow you to modify the visual spacing of start-of-line spaces?
- dTal 7y agoIt is a solved problem! Just use tabs. Almost every editor supports adjustable-width tabs. Why go out of your way to avoid tabs, and then make spaces behave like tabs?
- deleted 7y ago[deleted]
- themarkn 7y agoIt’s safer to assume that any code you write will at one point be maintained by somebody with a visual impairment even if there’s not currently a team member with an impairment.
- curiousgal 7y agoThis is a decent argument but calling it "the real reason" takes away from it.
- devit 7y agoYes, it's pretty obvious that Tab is correct since it has semantic meaning (tab = indent), is one character and has configurable width.
- dTal 7y agoThe reason it's more accessible is because it's The Right Way, in the same way that a text file is more accessible than a screenshot of that text file. Indentation is a semantic property, not a visual one.
- viraptor 7y ago> Indentation is a semantic property, not a visual one. Depending on style in can be both. +-- semantic v def something(with aligned, list of, parameters): ^ visual --+
- Pyxl101 7y agoThat’s a good point. If you need specific visual alignment with an arbitrary number of characters on the previous line, then spaces are appropriate. Tabs should be used for the initial semantic indentation then spaces for additional visual indentation beyond that. (Whether visual alignment of this sort is desirable is a different question. If you want it then spaces are appropriate.)
- krilly 7y agoThere is a difference between indentation and alignment. Unfortunately, python chose to enforce spaces only both via the language itself and pep8.
- ChrisSD 7y agoHow does the language enforce spaces only? PEP8 was only meant as a style guide for the python standard library. Although many have unfortunately taken it as a religious text.
- scrollaway 7y agoOh gods please don't align like this, it's just so unreadable. Example of what that does in practice: Lines that end up wrapping almost at the end of the soft-character-limit and look like this: https://github.com/pennersr/django-allauth/blob/c9b31ddee81d2cde06c1f686c4eb7703f916681f/allauth/account/views.py#L629-L632 https://github.com/pennersr/django-allauth/blob/c9b31ddee81d...
- feiss 7y agoI hope this is the seed to stop spaces nonsense..
- aaron695 7y agoIf there is a better way, it overrides the fact a visually impaired person, who has to set up specific settings and has a specific environment can just script the spaces to tabs and back when committing. We shouldn't not do the 'better' way for a few, that's a piss poor argument. A decent thing to do is help them to set the environment to suit themselves, why do people not care about this? Instead it's about dragging everyone else down rather then elevating them and their environment. Besides which, as the reddit comments mention, someone with visual impairments prefers spaces it's not even clear it's a good technical argument. This is just another culture war attempt.
- Sahhaese 7y agoWe discussed this 5 days ago: https://news.ycombinator.com/item?id=20341354 https://news.ycombinator.com/item?id=20341354
- vectorEQ 7y ago\t saves bytes compared to n*' '. there is literally no other reason to do this. for 'style' both can be implemented to do the same and most editors these days can replace one with the other and have configurable tabs, or 'use spaces instead of tabs' options. in reality, if for example you sent a lot of documents over the wire, or store a lot of documents on disk, using /t compared to spaces can save a lot of bytes on disk or network... (looking at the uncompressed case...)
- mstade 7y agoI've been a die hard 2-space indent person for well over a decade, but this is an argument I simply can't ignore and I feel compelled to reconsider my position. Thanks for sharing this!
- Pyxl101 7y agoHere’s another argument: If everyone uses tabs for indentation, then you can configure your editor to display that as 2 characters width, while the people who prefer 4 or 8 can do the same. No one needs to argue about how many columns of indentation there will be (1/2/4/8) since it’s specified in text semantically and displayed individually. No one needs to be die-hard N-space-ists since everyone can have their way simultaneously. Even code that wasn’t written by people who prefer your 2-column indent style (if they would otherwise be using spaces) will look that way to you. Everyone wins!
- vanderZwan 7y ago> (1/2/4/8) Sometimes I wonder if I'm the only person in the world with a preference for 3-character width tabs. I also wonder if I can ever bring up this topic in public without being called perverse by other programmers. People get really weirdly religious about this.
- bananicorn 7y agoOh, how come? What language are you using where 3-spaces-wide tabs are more comfortable?
- billforsternz 7y agoAn indentation preference can be largely language independent.
- dkersten 7y agoCan be and probably usually is. However, funnily enough, I have a language-dependent preference: 2 spaces or Lisp-like languages, 4 spaces for all others.
- timonoko 7y agoM-X tabify had two benefits. Firstly it more than halved assembly source paper tape. And secondly atleast Olivetti Teletype interpreted a TAB as a silent jump, instead of 8 bang-bang-bangs of empty spaces.
- _pmf_ 7y agoThat's the kind of practical real life inclusivity that I think should be pushed instead of the "being offended by theoretical straw men" code of conduct nonsense. But I won't hold my breath.
- splodge 7y agoIt's always fun pasting tab-indented code into the MySQL client...
- Faaak 7y agoThen fix the mysql client...
- scrollaway 7y agoBeen saying for years that tabs are an accessibility feature. It's good to see a thread get some traction. I've never understood why people -- logical people; programmers -- are so religious about spaces, especially in the Python community. A while back I tried to make the case to the author of Black (The python community's excellent auto-formatter) to add a "--use-tabs" option. I was not successful; I had to fork Black to be able to use it. https://github.com/jleclanche/tan https://github.com/jleclanche/tan
- theon144 7y agoTo be fair, Black's entire raison d'etre seems to be to not provide configuration unless absolutely necessary (for syntantic reasons, I'd imagine).
- scrollaway 7y agoAnd yet it does provide some configuration. :) Black has the same philosophy as Prettier, which does provide a --use-tabs option. And the whole "hey, accessibility" thing kind of rings as "absolutely necessary" in my book. I've had a bunch of people thank me for my fork because they wanted to use Black, but couldn't because they either preferred tabs or were required to use tabs. Similar reasons why Black provides a configurable max line length. I mean, I've had this argument with the author, I don't exactly want to go over it again :) The official reasoning for not including tabs as an option is that "tabs for indentation are the devil". https://github.com/python/black/issues/47 https://github.com/python/black/issues/47
- vanderZwan 7y ago> "tabs for indentation are the devil" Well, at least the author's honest about this being a religious argument, I guess
- dTal 7y agoMy impression is that many people are not confident in their understanding of tab behavior; there's a perception of them being weird, unpredictable voodoo (as exemplified by comments which imply that many programs don't support tabs well, despite that virtually all programs support tabs flawlessly, right down to notepad and standard GUI toolkit textboxes.) I think this stems from a broken mental model, whereby tabs are regarded as "representing x number of spaces", where x is some unknown variable in the editor of whoever created the file. These people say things like "tabs are just a compression mechanism" and "tabs are inconsistent across editors". In the minds of these people, spaces have primacy, and tabs are just weird inconsistent not-spaces that catch you out. The proper mental model, of course, is to recognize that tabs don't represent any number of spaces - they represent indents, and that's that. You could quite happily set your editor to display tabs as indents π spaces wide. It is an error on the part of the person writing the file to assume any particular tab width. There are a few coding style conventions that break the assumption that the indentation should strictly reflect the nesting depth, like breaking up a long argument list over multiple lines and trying to line the second line up with the opening parentheses. In my view these are bad coding styles anyway and should be retired.
- gopiandcode 7y agoI generally don't like using tabs, as I find having two characters for whitespace leads to annoying inconsistencies. However, were a team member request I use tabs for accessibility reasons, I would have no issue complying. That aside, I don't feel that this particular argument any stronger than any personal preference, let alone some kind of be-all final reason. Generally whenever more than one space is used consecutively it is intended for indentation purposes - thus an equivalent solution to the accessibility problem is to just configure the editor to render consecutive spaces differently. The post author calls for more editors to support adjusting tab widths showing that using tabs isn't automatically an accessibility win - spaces users could just as easily call for more editors to support custom ligatures to help the visually impaired.
- skohan 7y agoI actually find having a separate character for indentation is a strength of tabs rather than a detriment. Tabs tell you how the lines in your program relate to one another, and spaces tell you how things relate within a given line. On top of that, I think the strongest argument for tabs is efficiency. space-indented code uses 3 times as many bytes to represent a level of indentation than tab-delimited code. That might not seem like a lot, but spread over all the commits in all the codebases using spaces, it seems pointless to use all that extra disk space for no reason. I think the real problem is that the default tab width for web interfaces is 8 spaces. If it were a more reasonable 4 characters wide, I doubt it would even be an issue.
- pseudalopex 7y agoMore than one consecutive space is very frequently used for alignment. Converting on open and save would be simple otherwise. The author calls for more websites to support adjusting tab widths. What editor doesn't?
- maskros 7y agoI've been a tab user since forever. The biggest issue with using spaces is not how much you indent, it's the bad pattern of aligning stuff vertically beyond a simple N-level indent. Using spaces to align stuff on multiple lines causes multiple problems. Any changes will affect surrounding lines. This adds busy-work to realign everything, especially if you're not using a fancy editor plugin to do it. It also makes for bigger diffs, which add pointless noise when reading diffs, and potentially unneccessary merge/rebase conflicts. It's also assuming that the text is displayed in a monospaced font. A (very rare) few of us like to code with good looking proportianally spaced fonts instead of awkwardly spaced typewriter fonts.
- _ZeD_ 7y agoI cannot suggest enough to avoid this debate and pass to elastic tabstops http://nickgravgaard.com/elastic-tabstops/ http://nickgravgaard.com/elastic-tabstops/
- daghoidahl 7y agoI agree completely. Elastic tabstops are such an elegant solution to the whole debate. It turns the tab character into what it should be semantically, a character to denote alignment, just as it is used in a wysiwyg word processor. When supported by the editor, it also allows the user to align columns using a proportional font instead of the fixed-with fonts we have to use now. The concept has been discussed on HN earlier, but the accessibility argument is something that I hadn't considered or seen anyone discuss.
- afiori 7y agoWhy is this dead? It provides a commentary on the feature linked.
- jbverschoor 7y agoWould love to see a vscode plugin
- enriquto 7y agoI do not really care for tabs vs spaces, except in Python, where tabs are obviously the appropriate choice. For conceptual simplicity and orthogonality, if you want to treat python programs as text files, and deal with them using standard text processing tools, it is much more comfortable when the indentation is marked by a single character. Apart from that, I never cared if people used spaces in other programming languages (as long as it was 8 spaces per level, of course). But this reddit post highlights an important reason to promote tabs everywhere, not only in Python.
- IshKebab 7y agoDo you actually use 8 space indents??
- enriquto 7y agoOf course; I am a decent person. Let me just quote Linus Torvalds here: > Tabs are 8 characters, and thus indentations are also 8 characters. There are heretic movements that try to make indentations 4 (or even 2!) characters deep, and that is akin to trying to define the value of PI to be 3.
- amai 7y agoSpaces are for people who understand addition. Tabs are for people who understand multiplication. ;-)
- harimau777 7y agoSomething that I feel gets overlooked in tabs versus spaces is that a tab generally has a specific semantic meaning (increase indent by one) whereas a space's meaning depends on how many spaces you are using to indent and a single space has no meaning on its own (unless you are indenting using only one space). As a side note: I wish that JavaScript had a utility like the "indent" utility in Unix for precisely styling C code. Prettier is close; however, it cannot be customized in the detail that I would like.
- thiht 7y ago> however, it cannot be customized in the detail that I would like That's the whole point. Why is what you want better than what the formatter says?
- harimau777 7y agoI don't mean customized by an individual user, I mean customized by the team to fit their style guidelines.
- bryanlarsen 7y ago"it cannot be customized in the detail that I would like" Many people consider this a feature, not a bug.
- userbinator 7y agothese guys have serious problems using codebases with spaces, they have to convert, do their work, and then unconvert before committing I used to work for a company that had automatic formatting on checkin/checkout --- everyone had his/her own formatting preferences (tabs/spaces and how many was one of them), which deviated slightly from the "official" one, but the process was basically completely automatic. My personal preference is one space --- files are just as small as with tabs, and the column counter of the editor also directly corresponds to the indent level. Also, the lack of capitalisation and run-on sentences in a post arguing about accessibility is a bit ironic.
- mcv 7y agoAn excellent argument. I've been mostly agnostic about the tabs-vs-spaces debate, as long as we just pick one and stick with it everywhere consistently and never ever mix the two. I've had this feeling lately that maybe tabs might be more appropriate than spaces, but never felt strongly about it, and everybody has settled on spaces, so lets just stick with that. But in light of this argument, yes, lets move to tabs instead. More control for the user in how you actually display them.
- zimbatm 7y agoNobody talks about the fact that git can convert tabs to spaces and vice-versa on the fly so the whole discussion is irrelevant :-) https://stackoverflow.com/a/2316728 https://stackoverflow.com/a/2316728
- endorphone 7y agoTabs v spaces should be an argument that we are long past by now, our editors no longer bound by the limits that once fueled such arguments. Your editor should automatically purge all whitespace and format according to your settings and language canonical form. Whether tabs, spaces, curly braces on the end of line or next line, and on and on. Go coming with go fmt is one of the great things about the language because instantly so many color of the shed arguments were vanquished.
- JacKTrocinskI 7y agoUse tabs for indentation, space for alignment, why do it anyway else? I especially like Linus Torvalds view on indentation: "Tabs are 8 characters, and thus indentations are also 8 characters. There are heretic movements that try to make indentations 4 (or even 2!) characters deep, and that is akin to trying to define the value of PI to be 3. Rationale: The whole idea behind indentation is to clearly define where a block of control starts and ends. Especially when you've been looking at your screen for 20 straight hours, you'll find it a lot easier to see how the indentation works if you have large indentations. Now, some people will claim that having 8-character indentations makes the code move too far to the right, and makes it hard to read on a 80-character terminal screen. The answer to that is that if you need more than 3 levels of indentation, you're screwed anyway, and should fix your program." https://github.com/torvalds/linux/blob/master/Documentation/process/coding-style.rst https://github.com/torvalds/linux/blob/master/Documentation/...
- childintime 7y agoDespite adding a valid perspective, this is mostly clickbait. A file is just a storage format. The real issue is that IDE's don't render files according to user preferences, be them TABs or spaces, or PascalCase vs snake-case. When saving they convert back. No need to "get everybody on the same page" and in the process create winners and losers. Unlike laws (or like laws), technology has the capacity to create win-win situations. This is a good example. So the real question is why we insist on debates, instead of actually doing our jobs. Congress can only solve so much.
- ChrisSD 7y agoSurely version control solved this issue. Use whatever you like. Have a standard for the repository itself. Auto-convert if and when necessary.
- deleted 7y ago[deleted]