3 ms·
I liked working with FxCop and StyleCop. I liked seeing the expressions of frustration when developers that were sloppy with their coding style were no longer
by 29athrowaway 5y ago
I liked working with FxCop and StyleCop.
I liked seeing the expressions of frustration when developers that were sloppy with their coding style were no longer able to get away with code that didn't meet the coding standards.
When it was adopted it literally made some people scream in frustration, and I loved it for that.
The default ruleset of StyleCop is absolutely brutal and unforgiving with messy code.
- JackMorgan 5y agoI tend to be of the camp that if a tool can automatically detect issues, they usually aren't that important of an issue. The real messes that lose money can't be cleaned with a formatter or detected with a tool.
- EVa5I7bHFq9mnYK 5y agoI was tasked with running an autocorrector on all our code once in 6 months. On average, out of thousands problems it detected, 1-2 came out as real hard bugs, that would never been caught by programmers or the testing team. 1-2 bugs for a day of work is not that bad.
- 29athrowaway 5y agoSome problems could be fixed by autoformatting, some others could not because they involved a decision. For example: - StyleCop validated variable names beyond just casing, and forced you to decide how to comply. - StyleCop validated the number of arguments in methods, the length of a method and the length of statements. - StyleCop would identify situations when a variable should be created for a expression. Every large mess starts as a smaller mess, and that smaller mess is usually low quality code.