linux-test-project / lcov

LCOV
GNU General Public License v2.0
866 stars 234 forks source link

LCOV coverage.dat file has "DA:0:0" #290

Closed thomasbao12 closed 3 weeks ago

thomasbao12 commented 2 months ago

How can a file have a zeroth line? When I look at the line numbers corresponding to "FN:14...", I see that the 14th line of a file has the function declaration.

I can reproduce this on a company codebase using bazel, but I'm not sure how to reproduce this in a separate repo which I could share.

henry2cox commented 2 months ago

Which platform, tools and versions are you using (lcov, gcc/llvm, etc)?

My recollection is that python's Coverage.py sometimes reports line number zero in certain scenarios.

What function is it? Perchance, a compiler-generated one? Does the rest of the data for that file look reasonable? Or is everything off-by-one?

henry2cox commented 1 month ago

No update/no testcase. I presume that the issue is resolved or you no longer care about it.

I will go ahead and close this issue in a couple of days - unless there is something here that needs to be addressed.

henry2cox commented 3 weeks ago

Closing this issue now. If there is still a problem, please feel free to reopen this issue or file a new one. Please describe the problem in detail and provide a testcase which illustrates the issue, if possible.