← every case · 2000 · string forms
an apostrophe inside the body of a shell heredoc. The word that ends a heredoc is chosen where it is written, so no fixed list of comment and string symbols can say what closes this one
| 1 | codecodecodecodecodecode | cat <<TEXT |
| 2 | codecodecodecodecodecode | it's fine in here |
| 3 | codecodecodecodecodecode | TEXT |
| 4 | commentscommentscommentscommentscommentscomments | # a real comment |
| 5 | commentscommentscommentscommentscommentscomments | # a second real comment |
stringcommentthe tag around another language
cloc --json cases/2000-string_forms/2120-heredoc_holding_an_apostrophe/input.sh
--strip-str-comments
cloc --json cases/2000-string_forms/2120-heredoc_holding_an_apostrophe/input.sh --strip-str-comments
cloc --json cases/2000-string_forms/2120-heredoc_holding_an_apostrophe/input.sh --docstring-as-code
the apostrophe opens a string and every comment under it is counted as code
mezura cases/2000-string_forms/2120-heredoc_holding_an_apostrophe/input.sh --output json --hide timing --no-default-config --no-local --counting content
the apostrophe opens a string and every comment under it is counted as code
mezura cases/2000-string_forms/2120-heredoc_holding_an_apostrophe/input.sh --output json --hide timing --no-default-config --no-local --counting region
the apostrophe opens a string and every comment under it is counted as code
scc --format json cases/2000-string_forms/2120-heredoc_holding_an_apostrophe/input.sh
the apostrophe opens a string and every comment under it is counted as code
tokei --output json cases/2000-string_forms/2120-heredoc_holding_an_apostrophe/input.sh