3 ms·
The norm seems to be: Conform to what's currently in the code. Whether it's variable names, your brace style or indenting lengths, it doesn't matter if you thi
by ryandrake 12y ago
The norm seems to be: Conform to what's currently in the code.
Whether it's variable names, your brace style or indenting lengths, it doesn't matter if you think your way is the best, what matters is fitting in with the existing (shared) codebase so it's readable to everyone who has been working on it for the last 5 years.
Same is true for non-style things. If your project is 100K lines of 1998-era "C-with-classes" C++ code, your modern, templated, header-only, lambda-using work of art is going to cause more friction than it helps.
- taeric 12y agoAgreed. Just when you are talking sub 30kloc projects, I feel it would honestly be easier to just do a quick pass reformat in idiomatic style (tool supported being the main point) and then drop the conversation. Having to get every new member to realize that they can not just rely on the tool defaults is... sad.
- Retra 12y agoThis is why it is so awesome to encode your conventions into an auto-formatter.