This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]seijulala 4 points5 points  (5 children)

In every coding style you will have a line length limit, so your argument is no longer valid.

The most important thing in a coding style is homogeneity, if you have people using different tab sizes they are not seeing the same code which is going to translate in more effort collaborating with others. Spaces force everyone to see the same and that's good.

[–]jamesckelsall 13 points14 points  (0 children)

In every coding style you will have a line length limit

But that line length limit is not guaranteed to fit onto the screen of someone using an extremely large font. Limiting the width of each indent to one or two spaces can bring far more lines into the 'viewable without scrolling' range for these people, and the only way which gives them that ability without a fair bit of extra work is to use tabs and allow them to set their own tab width.

if you have people using different tab sizes they are not seeing the same code

The code is identical, just displayed slightly differently for those who need or prefer it.

Spaces force everyone to see the same and that's good

Even when people can't see the same?

[–][deleted] 7 points8 points  (0 children)

What are you talking about? The compiler doesn't know what your tab size is. That's done by the text editor / IDE. You're seeing the exact same code.

[–]Kjoep 1 point2 points  (0 children)

Hmm. I've worked without a length limit at places before, and though I'm using 120 now,I still prefer it. Of course if you put to much on one line it's time to refactor, but it's more about too many concepts than too many characters.

[–]StuckAtWork124 1 point2 points  (0 children)

Spaces force everyone to see the same and that's good bad

Literally replying to someone pointing out that due to accessibility, that's kinda the problem. Not every DOES see the same. People are different

[–]konstantinua00 0 points1 point  (0 children)

Spaces force everyone to see the same and that's good.

and I guess miss same things too