File tree Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -6475,8 +6475,15 @@ static std::unique_ptr<Module> emit_function(
6475
6475
BB[label] = bb;
6476
6476
}
6477
6477
6478
- if (do_coverage (mod_is_user_mod))
6478
+ if (do_coverage (mod_is_user_mod)) {
6479
6479
coverageVisitLine (ctx, ctx.file , toplineno);
6480
+ if (linetable.size () >= 1 ) {
6481
+ // avoid double-counting the entry line
6482
+ const auto &info = linetable.at (1 );
6483
+ if (info.file == ctx.file && info.line == toplineno && info.is_user_code == mod_is_user_mod)
6484
+ current_lineinfo.push_back (1 );
6485
+ }
6486
+ }
6480
6487
if (do_malloc_log (mod_is_user_mod))
6481
6488
mallocVisitLine (ctx, ctx.file , toplineno);
6482
6489
find_next_stmt (0 );
Original file line number Diff line number Diff line change 1
1
SF:<FILENAME>
2
- DA:4,2
2
+ DA:4,1
3
3
DA:5,0
4
4
DA:7,1
5
5
DA:8,1
You can’t perform that action at this time.
0 commit comments