Reputation: 42577
Question: Given that I control how "prog" is compiled/run; how can I get list of the lines of code that "./prog input-file" does not hit?
Thanks!
EDIT: I'm currently using g++; but perfeclty happy to switch to LLVM if it makes this possible.
Upvotes: 1
Views: 450
Reputation: 523154
gcc comes with a code coverage testing tool (gcov):
http://gcc.gnu.org/onlinedocs/gcc/Gcov.html
Upvotes: 2