As i said, `const string&` is what I commended. comapared with `string` it reduce several temporary string cont/dest call. It is mentioned in Effective C++ book ,http://stackoverflow.com/questions/6067407/why-sometime-a-function-return-a-const-or-const-reference. Your case is not the exception BTW.

Checked the code again, the impl return the `picojson::value::serialize` in some cases, while `serialize()` return `std::string`. With that case, I'm okay to return `std::string`