← every case · 5000 · line splices

5040-line_splice_in_a_comment_with_no_words

the splice of case 5030 on a comment line holding no letter or digit at all, which is how a decorative rule is written. What a line says has no bearing on whether it continues

read ascloc.defaultmezura.contentmezura.regionscc.defaulttokei.default
input.c
1codeint a = 1;
2comments// ---- \
3commentsint b = 2;
4codeint c = 3;

stringcommentthe tag around another language

What each tool answered

cloc.default ✗ fails

a comment carrying no letter or digit is read like any other and still stops at the line break, so the line spliced onto it counts as code

the rules ask4 lines · 0 blanks · 2 code · 2 comments
it answers4 lines · 0 blanks · 3 code · 1 comments

cloc --json cases/5000-line_splices/5040-line_splice_in_a_comment_with_no_words/input.c

mezura.content ✓ agrees
the rules ask4 lines · 2 code · 1 comments · 1 extra
it answers4 lines · 2 code · 1 comments · 1 extra

mezura cases/5000-line_splices/5040-line_splice_in_a_comment_with_no_words/input.c --output json --hide timing --counting content

mezura.region ✓ agrees
the rules ask4 lines · 0 blanks · 2 code · 2 comments
it answers4 lines · 0 blanks · 2 code · 2 comments

mezura cases/5000-line_splices/5040-line_splice_in_a_comment_with_no_words/input.c --output json --hide timing --counting region

scc.default ✗ fails

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

the rules ask4 lines · 0 blanks · 2 code · 2 comments
it answers4 lines · 0 blanks · 3 code · 1 comments

scc --format json cases/5000-line_splices/5040-line_splice_in_a_comment_with_no_words/input.c

tokei.default ✗ fails

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

the rules ask4 lines · 0 blanks · 2 code · 2 comments
it answers4 lines · 0 blanks · 3 code · 1 comments

tokei --output json cases/5000-line_splices/5040-line_splice_in_a_comment_with_no_words/input.c