82 comments
But my good horse for an editor that recognizes all spaces from the cursor back to the first column, and deletes the same number it puts in for a tab upon each press of the backspace key. @stevensrmiller @catsalad TextMate does that! But itโs basically abandoned and I canโt recommend it. @stevensrmiller @catsalad Or just use the correct indentation character (tab)
@housepanther @catsalad The whole point is that the reader gets to choose. @housepanther @catsalad Yes, I was on the losing side of that war. Still not convinced it was the wrong one. @rupert @housepanther @catsalad Because it wasn't. I was on team "don't care" for quite a long time, but since I stumbled upon this reddit post it is clear to me that tabs are a lot better: https://www.reddit.com/r/javascript/comments/c8drjo/nobody_talks_about_the_real_reason_to_use_tabs/ @weebull @rupert @housepanther @catsalad Aligning stuff is a horrible idea IMO anyway, since it forces you to change multiple lines as soon as one longer name term is introduced. Get rid of that and you'll have a better code base no matter if you are using tabs or spaces. @danrot @rupert @housepanther @catsalad I agree for separate statements, but you don't align to parenthesis in multiline statements? @housepanther @catsalad in my experience itโs usually either three or five spaces and I can never predict which. But usually one of those. @catsalad I was of the tabs persuasion but then I started using debuggers that would highlight the wrong bit of code unless I used spaces. @jeremy_list I just use tabs but have the editor replace them as spaces. Works well for me. I still get to use the tab key without pressing space 2, 4, 6 times but get the better compatibility of spaces. @aiuto ... and that recommendation was removed years ago: https://cs.opensource.google/go/go/+/25b51810014cefb8dba31321fcf40eb1a008fc3e Sorry for the bad advice. @catsalad Revealing whitespace can be like turning on a black light in a hotel room. ๐ฌ๐ณ @catsalad @eniko Reminded me of the one programming language optimized for printing source out: https://en.wikipedia.org/wiki/Whitespace_(programming_language) @RichardKogelnig @eniko That's an interesting read. Thanks for the link! @catsalad shouldn't really matter unless you are using Python which made the despicable and arguably insane decision to make the amount of whitespace syntactically and semantically meaningful. I stopped learning Python when I found out about that and didn't want to know what other stupidities were hidden within. A 4 panel meme comic titled "Tabs vs Spaces", in which a person is depicted rejecting the contents of an adjacent blank panel on the first row, followed by the same person expressing approval for another blank panel on the second row. This joke relies on visual ambiguity between tabs and spaces, neither of which are discernable from the blank background in the panels. It remains uncertain whether the person approves of tabs vs spaces. @ellie Thank you! Just found out you can edit image descriptions now, so I added your text. @catsalad BUT did the person who make this meme actually make a text placeholder containing a space and a tab, or did they ignore it knowing that it'd make no visual difference?
@catsalad @catsalad @catsalad @catsalad Just think, If you used just the one space, you could rotate your monitor to portrait and read more @catsalad Mind you, I am a writer and so tabs are essential for good print. If you can set the tabs and they will stay put. Unfortunately, Word for Windows and almost all other modern word processors are object oriented instead of text oriented (like the aforementioned WordPerfect), and anytime you change something or place an object, the program fucks with the tab settings. @catsalad not enough of you kids have dealt with make files, where the difference matters, for some insane reason. @catsalad Oh, I was a hardcore tab guy. Then I had a nicely-formatted router configuration file (with tab indents, naturally) and I pushed it into a router over serial. You know what a *nix OS does when it sees a tab on the command line? It does *not* ignore it as white space. It thinks you want "tab completion" and will happily replace that tab with... Something. Something that will completely mess up your router configuration and take you hours to troubleshoot. So now I'm a spaces guy. @ericphelps maybe it was the router's crap interface that made you do it, so don't take it personally... but if one time you threw soup into a running blender with no lid and it made a mess, do you complain about the blender and shun soup? PS: edited to make this sound less malignant, sorry. Tabs vs Spaces Image caption: |
@catsalad #c64