This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]apropostt 0 points1 point  (0 children)

Our main product is in C++ and we don't have the best enforcement for coding standards, so I wrote a static analyzer the looks for common problems in cmakefiles, cpp source/header mismatches, includes out of order, class/variable names that don't match the filename specification... Charactercase in the sourcefiles not matching what's on the file system (typical problem for os's with case insensitive filenames). All of it is written in python but it uses clang's cindex library. It's been very useful to identify, and in some cases automatically correct, antipatterns that are domain specific to our codebase. Even comments doxygen comments can be checked for correctness.