← every case · 1000 · comments

1130-closer_in_code_with_nothing_open

Rust ends a raw string with a quote and a hash, and those two characters appear here in ordinary code with no raw string open. They are a plain string holding a hash and nothing more. A counter that takes them for a closer anyway opens a string at the last quote, which hides the block comment opened after it whether its strings end with the line or run on

read ascloc.defaultcloc.docstring-as-codecodestats.defaultmezura.contentmezura.regionscc.defaulttokei.default
input.rs
1codelet s = "#"; /* a real comment
2commentsthat closes on this line */

stringcommentthe tag around another language

What each tool answered

cloc.default ✓ agrees
the rules ask2 lines · 0 blanks · 1 code · 1 comments
it answers2 lines · 0 blanks · 1 code · 1 comments

cloc --json --config /tmp/linejudge-empty-file cases/1000-comments/1130-closer_in_code_with_nothing_open/input.rs

cloc.default ✓ agrees

--strip-str-comments

the rules ask2 lines · 0 blanks · 1 code · 1 comments
it answers2 lines · 0 blanks · 1 code · 1 comments

cloc --json --config /tmp/linejudge-empty-file cases/1000-comments/1130-closer_in_code_with_nothing_open/input.rs --strip-str-comments

cloc.docstring-as-code ✓ agrees
the rules ask2 lines · 0 blanks · 1 code · 1 comments
it answers2 lines · 0 blanks · 1 code · 1 comments

cloc --json --config /tmp/linejudge-empty-file cases/1000-comments/1130-closer_in_code_with_nothing_open/input.rs --docstring-as-code

codestats.default ✓ agrees
the rules ask2 lines · 0 blanks · 1 code · 1 comments
it answers2 lines · 0 blanks · 1 code · 1 comments

codestats cases/1000-comments/1130-closer_in_code_with_nothing_open/input.rs --output json-compact --include-generated --no-gitignore --hidden --no-config

mezura.content ✓ agrees
the rules ask2 lines · 1 code · 1 comments · 0 extra
it answers2 lines · 1 code · 1 comments · 0 extra

mezura cases/1000-comments/1130-closer_in_code_with_nothing_open/input.rs --output json --hide timing --no-default-config --no-local --counting content

mezura.region ✓ agrees
the rules ask2 lines · 0 blanks · 1 code · 1 comments
it answers2 lines · 0 blanks · 1 code · 1 comments

mezura cases/1000-comments/1130-closer_in_code_with_nothing_open/input.rs --output json --hide timing --no-default-config --no-local --counting region

scc.default ✓ agrees
the rules ask2 lines · 0 blanks · 1 code · 1 comments
it answers2 lines · 0 blanks · 1 code · 1 comments

scc --format json --no-config cases/1000-comments/1130-closer_in_code_with_nothing_open/input.rs

tokei.default ✓ agrees
the rules ask2 lines · 0 blanks · 1 code · 1 comments
it answers2 lines · 0 blanks · 1 code · 1 comments

tokei --output json cases/1000-comments/1130-closer_in_code_with_nothing_open/input.rs