当前位置: 动力学知识库 > 问答 > 编程问答 >

Statistics from C++ source code

问题描述:

Do you know any type of tool, possibly for Linux and open source, that can be used to extract statistics from C/C++ source code files.

Apart from the number of lines, I would be interested in:

  • number of comment lines
  • number of classes used
  • number of declarations

and so on.

网友答案:

I use CLOC (http://cloc.sourceforge.net/) for counting lines of code, blank lines and comments. However CLOC does not interpret the code and thus cannot count classes, declarations etc.

And one should probably mention that this kind of statistics is considered meaningless by most people...

分享给朋友:
您可能感兴趣的文章:
随机阅读: