-1

In a big VS project I need to find functions (methods really) that are defined in the header, but simply never implemented. These functions are never called, so no errors are generated. Libraries used are of no concern here.

Is there a VS tool, compiler flag or a C++ trick to find such functions?

bolov
  • 72,283
  • 15
  • 145
  • 224
  • Possible duplicate of [Finding "dead code" in a large C++ legacy application](https://stackoverflow.com/questions/2380153/finding-dead-code-in-a-large-c-legacy-application) – AMA Oct 16 '17 at 13:46
  • maybe grepping and merging all the dumpbin /SYMBOLS objectfile ( with linktime optimization disabled ) outputs ? – Massimiliano Janes Oct 16 '17 at 14:14
  • Wondering did you try anything to find them? – Leedehai Sep 10 '19 at 18:30

1 Answers1

0

From what I know, in g++ there is a flag called -Wunused

Here is the documentation gcc.flags

It should point out the variables that are unused or the functions which are not in use.

JohnnyOnPc
  • 386
  • 1
  • 5
  • 18
  • it doesn't warn for functions. And even if it did, I can't compile the program on a linux environment. – bolov Oct 16 '17 at 13:49