1

output of gcov says no of lines executed 70 % of 10

but my code has more than 10 lines..

it does not count braces , else statement

please help ..

sarath
  • 31
  • 4

1 Answers1

1

gcov only counts lines of code that actually make it into the binary - braces are just part of the syntax.

Presumably the else is being optimized/compiled out?

Douglas Leeder
  • 52,368
  • 9
  • 94
  • 137