| 4267 | String valueToString(bool value) { return value ? "true" : "false"; } |
| 4268 | |
| 4269 | static bool doesAnyCharRequireEscaping(char const* s, size_t n) { |
| 4270 | assert(s || !n); |
| 4271 | |
| 4272 | return std::any_of(s, s + n, [](unsigned char c) { |
| 4273 | return c == '\\' || c == '"' || c < 0x20 || c > 0x7F; |
| 4274 | }); |
| 4275 | } |
| 4276 | |
| 4277 | static unsigned int utf8ToCodepoint(const char*& s, const char* e) { |
| 4278 | const unsigned int REPLACEMENT_CHARACTER = 0xFFFD; |
no test coverage detected