| 407 | } |
| 408 | |
| 409 | bool WriteComment(ostream_wrapper& out, const std::string& str, |
| 410 | std::size_t postCommentIndent) { |
| 411 | const std::size_t curIndent = out.col(); |
| 412 | out << "#" << Indentation(postCommentIndent); |
| 413 | out.set_comment(); |
| 414 | int codePoint; |
| 415 | for (std::string::const_iterator i = str.begin(); |
| 416 | GetNextCodePointAndAdvance(codePoint, i, str.end());) { |
| 417 | if (codePoint == '\n') { |
| 418 | out << "\n" |
| 419 | << IndentTo(curIndent) << "#" << Indentation(postCommentIndent); |
| 420 | out.set_comment(); |
| 421 | } else { |
| 422 | WriteCodePoint(out, codePoint); |
| 423 | } |
| 424 | } |
| 425 | return true; |
| 426 | } |
| 427 | |
| 428 | bool WriteAlias(ostream_wrapper& out, const std::string& str) { |
| 429 | out << "*"; |
no test coverage detected