There exist tools for comparing code against a custom specified set of coding guidelines/standards for a variety of languages (rather than pure static analysis for common defects). Examples include FxCop for .Net code and CheckStyle for Java, but I was wondering what examples people know of in the C++ world.
An existing question was asked regarding free tools which provided examples like Vera but I was also wondering about commercial tools that may be available.
Visual Studio Team System Edition 2005/2008 does have some such stuff. They also have a facility to enforce a set of rules on a whole team. Check it out.
The full list that I managed to generate:
The last two provide some functionality but not particularly customisable ones:
astyle
is a common Unix tool that reformats source to a specified style. It supports most C-like languages. I know of no similar commercial tools.DISCLAIMER: Working on this tool is my day job.
I'm obviously biased, but one of the main features of QA C++ is Coding Standard enforcement. For example we do JSF++ and MISRA C++ enforcement. You can read more about this here.
A tool used by us was CodeWizard from Parasoft. But I think the new version is called "Parasoft C++ Test". From the homepage:
I do not know whether you looking for a tool with built-in rules or want to validate against your custom rules. If it is the second, you may find it useful to implement searches for undesirable patterns based on regexp. Depending on your needs, Metrix++ http://metrixplusplus.sourceforge.net/ may offer helpful framework.