← every case · 5000 · line splices

5070-blank_line_inside_a_spliced_comment

a backslash at the end of a line comment carries it onto the blank line under it, so a line holding nothing at all is still inside the comment. Blank to a counter that asks what the line itself says, comment to one that asks what it is inside, and a counter that never sees the splice does not face the question

read ascloc.defaultmezura.contentmezura.regionscc.defaulttokei.default
input.c
1comments// the blank line below is still this comment \
2blanks
3codeint x = 1;

stringcommentthe tag around another language

What each tool answered

cloc.default ✗ fails

the blank line under the spliced comment is read as continuing it and is never blank, so it comes out comment where its own blanks-first rule says a line of nothing is blank

the rules ask3 lines · 1 blanks · 1 code · 1 comments
it answers3 lines · 0 blanks · 1 code · 2 comments

cloc --json cases/5000-line_splices/5070-blank_line_inside_a_spliced_comment/input.c

mezura.content ✓ agrees
the rules ask3 lines · 1 code · 1 comments · 1 extra
it answers3 lines · 1 code · 1 comments · 1 extra

mezura cases/5000-line_splices/5070-blank_line_inside_a_spliced_comment/input.c --output json --hide timing --counting content

mezura.region ✓ agrees
the rules ask3 lines · 0 blanks · 1 code · 2 comments
it answers3 lines · 0 blanks · 1 code · 2 comments

mezura cases/5000-line_splices/5070-blank_line_inside_a_spliced_comment/input.c --output json --hide timing --counting region

scc.default ✗ fails

the comment ends at the newline, so the empty line joined to it is counted as blank

the rules ask3 lines · 0 blanks · 1 code · 2 comments
it answers3 lines · 1 blanks · 1 code · 1 comments

scc --format json cases/5000-line_splices/5070-blank_line_inside_a_spliced_comment/input.c

tokei.default ✗ fails

the comment ends at the newline, so the empty line joined to it is counted as blank

the rules ask3 lines · 0 blanks · 1 code · 2 comments
it answers3 lines · 1 blanks · 1 code · 1 comments

tokei --output json cases/5000-line_splices/5070-blank_line_inside_a_spliced_comment/input.c