Sticky Bits » Style vs. Substance in C programming

Posted on 2013/06/23

0


Sticky Bits blog published an article on C style guides, and the importance of clarifying the real reasons behind these guidelines:

Sticky Bits » Blog Archive » Style vs. Substance in C programming.

The bottom line is that they (Feabhas) intend to develop a meta-guide that specifies how to write coding styles. They want a community-driven approach, and hope to improve the quality of software indirectly, by improving the quality of style guides.

I briefly talked about programming styles before, collecting some coding styles from different languages. I agree with the importance of understanding why a style is suggested (readability, compatibility, robustness, reducing errors in writing code, …), but I have doubts of a practical utility of a meta-guideline. Once it’s ready, it needs to be applied on new and existing coding style guides, which are written by many different entities that have to accept its value first, and then take the effort to apply it. But before that, if the project of writing this meta-guide is community driven, I’m afraid of the “bike shed effect“, where everyone feels entitled to say something because they know their way is right.

My suggestion to Feabhas would be to keep it transparent (read-only to everyone), but to not involve everyone on the net on the issue. It’s probably better to ask the right people (in terms of technical skills and cooperation attitude) to participate and keep the number of developers to a manageable number. Then, once the meta-guide is done (or while it is being written), take existing public code style guides and correct them (or rewrite them) under the meta-guide rules. This is similar to forking a project and adding your needed features, and similarly you could ask for “pulling” your modifications back into the upstream guide.

Anyway my hope is that by having a rational conversation our understanding of the issues will improve, and then we (as an ecosystem of software developers) can progress towards better code and better programs.

 

Posted in: Software