[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

Which do you use?

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 42
Thread images: 2

File: tabs-vs-spaces.jpg (126KB, 1440x679px) Image search: [Google]
tabs-vs-spaces.jpg
126KB, 1440x679px
Which do you use?
>>
indent with tabs, align with spaces
>>
>>58673710

I think tabs make more logical sense since they are more purposeful and take less keystrokes.

The only time that tabs suck is when dealing with data in tree structures (i.e. mostly HTML), but I think that speaks to HTML's weakness more than it speaks to the weakness of using tabs.

I switched to spaces though because it is trendy as fuck and I need to be a hipster (completely serious).
>>
i use spaces but who fucking cares
>>
>>58673710
Tabs require less key presses and memory, they are also customizable
>>
>>58674073
>Tabs require less key presses
This isn't valid if you use any text editor more advanced than Notepad
>>
>>58674073
Tabs can be converted to spaces. No-one actually presses space 4 times for each indentation in a newline.
>>
>>58674076
You still have two other reasons.
>>
at work: whatever code standard requires
on personal projects: who gives a shit

only freshmen CS students care about this btw
>>
Tabs because I'm not mentally retarded.
>>
>>58673710
Doesn't matter. I don't see whitespace, I don't type whitespace. My editor handles it all for me according to whatever style my current project/job demands.
>>
Threadly reminder that if you say tabs require less key presses, you're a Notepad-using noob whose opinion is worthless.
>>
Spaces all the way. Tabs are inconsistent.
>>
>>58673710
Tabs, I wrote it into the safety related software standard here so now all the coders here have to do it for when we are audited.
>>
>>58674038
>I think tabs make more logical sense since they are more purposeful and take less keystrokes.

Are you implying people are pressing spacebar e.g. 4 times to indent? lol

Also tabs are not uniform around the world, but spaces are.
>>
>>58673710
Tabs for everything. Mixing tabs and spaces is retarded because there's always some bloody wankstain who insists on four-character tabs (?!). Spaces are inefficient for storage and take less work to delete.

That said, I do use spaces where it is customary to use them, i.e. two-space indent in Ruby and four-space indent in Python.
>>
>>58674406
>Spaces are inefficient for storage
Stop saving your work on floppy disks, gramps...
>>
>>58674433
I still happen to program ancient PDP-10s.
>>
File: 1485332931265.jpg (83KB, 344x382px) Image search: [Google]
1485332931265.jpg
83KB, 344x382px
>>58674406

>tabs are inefficient for storage
>>
>>58674384
people who press tab to enter 4 spaces are really retarded
>>
>>58674494
>people who use tabs when tabs are different lengths throughout the world are really retarded
>>
>>58674494
When I press tab, my editor is told to indent, not insert tabs or spaces.
Stop using shitty editors that doesn't know how to indent.
>>
>>58674504
I never came across that specific problem, but it'll be really easy to just change the width of tabs in any program i wrote.
Not an issue.
>>
>>58673710
Tabs forever bitch.
>>
tabs.. that's what they're there for.

javascript hipster cunts want to use spaces for some reason, they can suck my cock
>>
>>58674076
>>58674084
This is true if you're creating indentation (a single tab press to generate 4 spaces).

However if you to delete it, or move your cursor over it, you still have to do 4 key presses, compared to tab which would still only need a single one.
>>
I press the tab key and the code indents. I don't give a fuck, it can use NULL characters for all I care.
>>
>>58674545
>you still have to do 4 key presses

Not that I use spaces (or maybe I do, I honestly don't know), but what kind of piece of shit editor do you use that doesn't treat backspace as a "unindent" key when you try to delete whatever you have configured for indenting?
>>
>>58674545
>if you want to delete 4 spaces you have to use 4 keystrokes

lol no. ctrl+shift+ left arrow key lets you select entire words (or groups of spaces) at a time. amazing, right?

this works everywhere, even the 4chan reply box, or your browser's address bar.
>>
>>58674561
>but what kind of piece of shit editor do you use that doesn't treat backspace as a "unindent" key when you try to delete whatever you have configured for indenting?
BlueJ
>>
>>58674561
you're on the tabs camp, get over it
>>
>>58673716
this
>>
>>58673710
Lisp doesn't use tabulation.
>>
>>58674545
Found the notepad user.
>>
probelm solved
syntax on
set bg=dark
set nocompatible
set shiftwidth=2
set expandtab
set tabstop=2
set softtabstop=2
>>
>>58674504
>tabs can be set to diffenrent width
that's a feature.
>>
>>58673710
I let emacs indent my Lisp code for me.
>>
>>58673716
This is the only correct answer.
>>
>>58673716
fpbp
>>
Does this matter?
>>
2 spaces
>>
>his text editor doesn't automatically convert tabs to spaces
Thread posts: 42
Thread images: 2


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.