I’ve added an Artistic Style options file .astylerc to the Rack repo’s root which auto-formats Rack’s source code. (See its documentation.) Most of Rack’s source code follows this style, but I’m considering tweaking it a bit, running the script on the entire repo, and reviewing changes.
perhaps enforce curly brackets for if statements and other blocks? weird bugs can come in here. a famous apple ssl bug was due to missing these brackets
Evaluated that but decided against it. It inflates the codebase by 1000 lines, and it’s a lot of vertical screen space when working with a lot of if () return logic. Also, Apple’s bug would be solved by the auto-indenter.
Coding styles have the advantage of being easy to automate. I disagree mostly with the choices outlined above but I have had to make MASSIVE changes in coding style every time I change jobs, so whatever seems right to you.
I am not a Rack developer anyway, just interested in the project. I’ve read enough of the source to be a fan of the design and implementation choices, I’ll overlook your terrible taste in code formatting