Document that length-aware string functions have been added in 2.7

This commit is contained in:
Philipp Stephani 2017-12-10 16:53:01 +01:00
parent 009ffa3fc8
commit 3951d39b40

View File

@ -332,6 +332,8 @@ length-aware functions if you wish to embed null bytes in strings.
Like :func:`json_string`, but with explicit length, so *value* may
contain null characters or not be null terminated.
.. versionadded:: 2.7
.. function:: json_t *json_string_nocheck(const char *value)
.. refcounting:: new
@ -347,6 +349,8 @@ length-aware functions if you wish to embed null bytes in strings.
Like :func:`json_string_nocheck`, but with explicit length, so
*value* may contain null characters or not be null terminated.
.. versionadded:: 2.7
.. function:: const char *json_string_value(const json_t *string)
Returns the associated value of *string* as a null terminated UTF-8
@ -361,6 +365,8 @@ length-aware functions if you wish to embed null bytes in strings.
Returns the length of *string* in its UTF-8 presentation, or zero
if *string* is not a JSON string.
.. versionadded:: 2.7
.. function:: int json_string_set(json_t *string, const char *value)
Sets the associated value of *string* to *value*. *value* must be a
@ -372,6 +378,8 @@ length-aware functions if you wish to embed null bytes in strings.
Like :func:`json_string_set`, but with explicit length, so *value*
may contain null characters or not be null terminated.
.. versionadded:: 2.7
.. function:: int json_string_set_nocheck(json_t *string, const char *value)
Like :func:`json_string_set`, but doesn't check that *value* is
@ -384,6 +392,8 @@ length-aware functions if you wish to embed null bytes in strings.
Like :func:`json_string_set_nocheck`, but with explicit length,
so *value* may contain null characters or not be null terminated.
.. versionadded:: 2.7
Number
======