4 ms·
I find the Horstmann indentation style [1], in which code is placed on the same line as the opening bracket, simultaneously disturbing and compelling. If it eve
by iamthad 5y ago
I find the Horstmann indentation style [1], in which code is placed on the same line as the opening bracket, simultaneously disturbing and compelling. If it ever ends up added to clang-format as has been requested [2], it might become more popular.
[1] https://en.wikipedia.org/wiki/Indentation_style#Horstmann_style https://en.wikipedia.org/wiki/Indentation_style#Horstmann_st...
[2] https://bugs.llvm.org/show_bug.cgi?id=27263 https://bugs.llvm.org/show_bug.cgi?id=27263
- pkulak 5y agoOh my God, I think I like it.
- mikewarot 5y agoI like it too. It makes C code actually look readable. It would be interesting to see it applied to Lisp code.
- muzani 5y agoThis is actually very sensible. I don't like the top bracket being its own line, but there's good reason for it to align with the bottom bracket.
- videogreg93 5y agoJava style formatting removes the "bracket on its own line" problem, so I'm not sure how this new indentation style adds anything of value really.
- adamhp 5y agoIt is fascinating that we've developed a sense of aesthetics around this, though I suppose it is to be expected with how much we are oriented around language. I personally use 1TBS wherever possible. It just looks the cleanest to me.