mirror of
https://github.com/nlohmann/json.git
synced 2026-07-10 12:35:09 +00:00
deploy: fe0299545a
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -38,6 +38,10 @@ This implementation is interoperable as it does compare strings code unit by cod
|
||||
|
||||
String values are stored as pointers in a `basic_json` type. That is, for any access to string values, a pointer of type `string_t*` must be dereferenced.
|
||||
|
||||
#### Cross-`basic_json` conversion requirements
|
||||
|
||||
When converting a string value from one `basic_json` specialization to another via the [converting constructor](https://json.nlohmann.me/api/basic_json/basic_json/#overload-4), the target `string_t` must be directly constructible from the source `basic_json`'s `string_t` type. If this requirement is not met, the conversion does not fail; instead, the string is silently converted as an array of character codes, which is incorrect. See [issue #3425](https://github.com/nlohmann/json/issues/3425) for details and an example.
|
||||
|
||||
## Examples
|
||||
|
||||
Example
|
||||
|
||||
Reference in New Issue
Block a user