https://bugs.llvm.org/show_bug.cgi?id=34059

            Bug ID: 34059
           Summary: source-based code coverage shows coverage for
                    constants defined with #define
           Product: new-bugs
           Version: unspecified
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: new bugs
          Assignee: unassignedb...@nondot.org
          Reporter: efrie...@codeaurora.org
                CC: llvm-bugs@lists.llvm.org, v...@apple.com

Consider the following:

#define VAL -1
int f(void) {
  return VAL;
}

If you generate a coverage report, we show coverage for the code in f()... and
we also show coverage for "-1".  I guess that's correct, in some sense, but it
isn't really useful; the user thinks of it as a constant, not code.

On its own, this doesn't matter much.  But it gets annoying when you generate a
coverage report for a C codebase: the report includes a bunch of headers which
don't contain any code.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to