What tool can show maximum statements of a method or function in C ++?

our project is really big. source code size is about 620KLOC in one module. So I want to check which function is the largest in the directory / module? Is there any tool to support it?

SourceMonitor has only "Average expressions for each method", and not maximum operators for each method. Nor does it support it.

Example. This function length is 1.

unsigned short get()
{
    return 1;
}

Thank.

+5
source share
4 answers

The easiest thing I can think of is to make my way through it.

  • Use ctags to get a list of functions in a file
  • perl/python/awk/grep ,
  • , . , -, . sloccount

    . grep, , .

, :

Lazy ++: Is - , , ++ . , lzz , . , .

+2

SourceMeter, CSV, /, ( , ), (, , , ). , / .

+1

, , , , , ( , ) .

, , . , , .cpp. , ( , - /OPT:REF Visual Studio). . , .cpp. : script, objdump (VisualStudio) nm -C (gcc), , , .

- cpp. #ifdef #includes . ( , , , ). #ifdef , . , , .

, , , , -. , , , , , , .

0

CppDepend , Clang, CQLinq , .

0

All Articles