mirror of
https://github.com/jbeder/yaml-cpp.git
synced 2025-09-09 20:51:16 +00:00
Fix formatting when writing \ as a character.
This commit is contained in:
@@ -380,6 +380,8 @@ bool WriteChar(ostream_wrapper& out, char ch) {
|
||||
out << "\"\\n\"";
|
||||
} else if (ch == '\b') {
|
||||
out << "\"\\b\"";
|
||||
} else if (ch == '\\') {
|
||||
out << "\"\\\\\"";
|
||||
} else if ((0x20 <= ch && ch <= 0x7e) || ch == ' ') {
|
||||
out << "\"" << ch << "\"";
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user