mirror of
https://github.com/KingDuckZ/kamokan.git
synced 2024-11-23 00:33:44 +00:00
Eat up the newline following the html comment.
This commit is contained in:
parent
9c0734c31d
commit
eb02bd617b
1 changed files with 2 additions and 1 deletions
|
@ -59,7 +59,8 @@ namespace kamokan {
|
|||
if (parPastie.npos != comment_start) {
|
||||
const auto comment_len = parPastie.find("-->") - comment_start + 3;
|
||||
retval.comment = parPastie.substr(comment_start, comment_len);
|
||||
parPastie.erase(comment_start, comment_len);
|
||||
const std::size_t newline = (comment_len + 1 < parPastie.size() and parPastie[comment_len] == '\n' ? 1 : 0);
|
||||
parPastie.erase(comment_start, comment_len + newline);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue