mirror of
https://github.com/nlohmann/json.git
synced 2026-10-05 14:10:31 +00:00
deploy: 63c10a51fc
This commit is contained in:
@@ -26,6 +26,8 @@ When the macro is not defined, the library behaves as if it were defined to its
|
||||
To prepare existing code, define `JSON_USE_GLOBAL_UDLS` to `0` and bring the string literals into scope where
|
||||
needed. Refer to any of the [string literals](#see-also) for details.
|
||||
|
||||
See the [migration guide](../../integration/migration_guide.md#import-namespace-literals-for-udls) for how to update existing code.
|
||||
|
||||
!!! hint "CMake option"
|
||||
|
||||
The placement of user-defined string literals can also be controlled with the CMake option
|
||||
@@ -39,7 +41,7 @@ When the macro is not defined, the library behaves as if it were defined to its
|
||||
|
||||
## Examples
|
||||
|
||||
??? example "Example 1: Default behavior"
|
||||
??? example "Example: Default behavior"
|
||||
|
||||
The code below shows the default behavior using the `_json` UDL.
|
||||
|
||||
@@ -62,7 +64,7 @@ When the macro is not defined, the library behaves as if it were defined to its
|
||||
42
|
||||
```
|
||||
|
||||
??? example "Example 2: Namespaced UDLs"
|
||||
??? example "Example: Namespaced UDLs"
|
||||
|
||||
The code below shows how UDLs need to be brought into scope before using `_json` when `JSON_USE_GLOBAL_UDLS` is
|
||||
defined to `0`.
|
||||
|
||||
Reference in New Issue
Block a user