Open shierei opened 7 years ago
Using john.get("age").to<std::string>()
to convert works.
If the documentation is incorrect or unclear could you please add a link to the page and what is unclear or wrong. Thanks.
The document that I was referring to is here https://billyquith.github.io/ponder/docs/classponder_1_1_value.html#details.
Based on this, you might think that the assignment would do the type conversion when assigning a number string to a number directly. It does not compile. This is no big deal because class ponder::Value overloads operator T() and it does the conversion correctly for other cases, such as passing a Value to a function argument of a string or a number type.
From the document, it looks like I should be able to assign a ponder::Value to a std::string but I get the following compiler error.
Is this expected?