Commit 78a7ecb9 authored by Jamie Seward's avatar Jamie Seward

Add std::string overload to PrettyWriter::Key() when RAPIDJSON_HAS_STDSTRING is #defined

Only String() has the std::string overload currently.
parent 67d8a994
...@@ -115,6 +115,12 @@ public: ...@@ -115,6 +115,12 @@ public:
} }
bool Key(const Ch* str, SizeType length, bool copy = false) { return String(str, length, copy); } bool Key(const Ch* str, SizeType length, bool copy = false) { return String(str, length, copy); }
#if RAPIDJSON_HAS_STDSTRING
bool Key(const std::basic_string<Ch>& str) {
return Key(str.data(), SizeType(str.size()));
}
#endif
bool EndObject(SizeType memberCount = 0) { bool EndObject(SizeType memberCount = 0) {
(void)memberCount; (void)memberCount;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment