mirror of
https://github.com/nlohmann/json.git
synced 2026-10-05 06:00:29 +00:00
deploy: ed513715a8
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -80,6 +80,14 @@ When defined, the library will not create a compile error when a known unsupport
|
||||
|
||||
See [full documentation of `JSON_SKIP_UNSUPPORTED_COMPILER_CHECK`](https://json.nlohmann.me/api/macros/json_skip_unsupported_compiler_check/index.md).
|
||||
|
||||
## `JSON_STRICT_NUL_HANDLING`
|
||||
|
||||
When defined to `1`, a `'\0'` (NUL) byte anywhere in the input is rejected with `parse_error.101`, like any other unexpected byte, instead of being silently treated as end of input (see the [FAQ entry](https://json.nlohmann.me/home/faq/#nul-bytes-in-the-input) for background). The default value is `0`, which preserves the existing behavior; this is planned to become the default in version 4.0.0.
|
||||
|
||||
The strict handling can also be enabled with the CMake option [`JSON_StrictNulHandling`](https://json.nlohmann.me/integration/cmake/#json_strictnulhandling) (`OFF` by default) which sets `JSON_STRICT_NUL_HANDLING` accordingly.
|
||||
|
||||
See [full documentation of `JSON_STRICT_NUL_HANDLING`](https://json.nlohmann.me/api/macros/json_strict_nul_handling/index.md).
|
||||
|
||||
## `JSON_THROW_USER(exception)`
|
||||
|
||||
This macro overrides `throw` calls inside the library. The argument is the exception to be thrown.
|
||||
|
||||
Reference in New Issue
Block a user