Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
json
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
json
Commits
662a9b8f
Unverified
Commit
662a9b8f
authored
Feb 08, 2017
by
Niels Lohmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
✏
fixed more typos
parent
4746a4c5
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
42 additions
and
42 deletions
+42
-42
src/json.hpp
src/json.hpp
+21
-21
src/json.hpp.re2c
src/json.hpp.re2c
+21
-21
No files found.
src/json.hpp
View file @
662a9b8f
...
...
@@ -1106,7 +1106,7 @@ class basic_json
/*!
@brief returns version information on the library
This function returns a JSON object with inf
i
ormation about the library,
This function returns a JSON object with information about the library,
including the version number and information on the platform and compiler.
@return JSON object holding version information
...
...
@@ -3417,7 +3417,7 @@ class basic_json
/*!
@brief get a reference value (implicit)
Implict reference access to the internally stored JSON value. No copies
Implic
i
t reference access to the internally stored JSON value. No copies
are made.
@warning Writing data to the referee of the result yields an undefined
...
...
@@ -3492,7 +3492,7 @@ class basic_json
template
<
typename
ValueType
,
typename
std
::
enable_if
<
not
std
::
is_pointer
<
ValueType
>
::
value
and
not
std
::
is_same
<
ValueType
,
typename
string_t
::
value_type
>::
value
#ifndef _MSC_VER // fix for issue #167 operator<< abiguity under VS2015
#ifndef _MSC_VER // fix for issue #167 operator<< a
m
biguity under VS2015
and
not
std
::
is_same
<
ValueType
,
std
::
initializer_list
<
typename
string_t
::
value_type
>>::
value
#endif
,
int
>::
type
=
0
>
...
...
@@ -4285,7 +4285,7 @@ class basic_json
@complexity The complexity depends on the type:
- objects: amortized constant
- arrays: linear in distance between pos and the end of the container
- arrays: linear in distance between
@a
pos and the end of the container
- strings: linear in the length of the string
- other types: constant
...
...
@@ -5537,7 +5537,7 @@ class basic_json
@throw std::domain_error if @a pos is not an iterator of *this; example:
`"iterator does not fit current value"`
@complexity Constant plus linear in the distance between pos and end of
@complexity Constant plus linear in the distance between
@a
pos and end of
the container.
@liveexample{The example shows how `insert()` is used.,insert}
...
...
@@ -6234,7 +6234,7 @@ class basic_json
`std::setw(4)` on @a o sets the indentation level to `4` and the
serialization result is the same as calling `dump(4)`.
@note During serializaion, the locale and the precision of the output
@note During serializa
t
ion, the locale and the precision of the output
stream @a o are changed. The original values are restored when the
function returns.
...
...
@@ -10624,7 +10624,7 @@ basic_json_parser_66:
if
(
m_stream
==
nullptr
or
m_stream
->
eof
())
{
// m_start may or may not be pointing into m_line_buffer at
// this point. We trust the standa
n
d library to do the right
// this point. We trust the standa
r
d library to do the right
// thing. See http://stackoverflow.com/q/28142011/266378
m_line_buffer
.
assign
(
m_start
,
m_limit
);
...
...
@@ -10712,7 +10712,7 @@ basic_json_parser_66:
m_start + 1 + x < m_cursor - 1 must hold to loop indefinitely. This
can be rephrased to m_cursor - m_start - 2 > x. With the
precondition, we x <= 0, meaning that the loop condition holds
indefinitly if i is always decreased. However, observe that the value
indefinit
e
ly if i is always decreased. However, observe that the value
of i is strictly increasing with each iteration, as it is incremented
by 1 in the iteration expression and never decremented inside the loop
body. Hence, the loop condition will eventually be false which
...
...
@@ -10841,12 +10841,12 @@ basic_json_parser_66:
/*!
@brief parse floating point number
This function (and its overloads) serves to select the most approprate
This function (and its overloads) serves to select the most appropr
i
ate
standard floating point number parsing function based on the type
supplied via the first parameter. Set this to @a
static_cast<number_float_t*>(nullptr).
@param[in,out] endptr rec
ie
ves a pointer to the first character after
@param[in,out] endptr rec
ei
ves a pointer to the first character after
the number
@return the floating point number
...
...
@@ -10859,12 +10859,12 @@ basic_json_parser_66:
/*!
@brief parse floating point number
This function (and its overloads) serves to select the most approprate
This function (and its overloads) serves to select the most appropr
i
ate
standard floating point number parsing function based on the type
supplied via the first parameter. Set this to @a
static_cast<number_float_t*>(nullptr).
@param[in,out] endptr rec
ie
ves a pointer to the first character after
@param[in,out] endptr rec
ei
ves a pointer to the first character after
the number
@return the floating point number
...
...
@@ -10877,12 +10877,12 @@ basic_json_parser_66:
/*!
@brief parse floating point number
This function (and its overloads) serves to select the most approprate
This function (and its overloads) serves to select the most appropr
i
ate
standard floating point number parsing function based on the type
supplied via the first parameter. Set this to @a
static_cast<number_float_t*>(nullptr).
@param[in,out] endptr rec
ie
ves a pointer to the first character after
@param[in,out] endptr rec
ei
ves a pointer to the first character after
the number
@return the floating point number
...
...
@@ -10925,7 +10925,7 @@ basic_json_parser_66:
// maximum absolute value of the relevant integer type
number_unsigned_t
max
;
// temporarily store the type to avoid unecessary bitfield access
// temporarily store the type to avoid un
n
ecessary bitfield access
value_t
type
;
// look for sign
...
...
@@ -11558,7 +11558,7 @@ basic_json_parser_66:
if
(
reference_token
==
"-"
)
{
// explicit
y
ly treat "-" as index beyond the end
// explicitly treat "-" as index beyond the end
ptr
=
&
ptr
->
operator
[](
ptr
->
m_value
.
array
->
size
());
}
else
...
...
@@ -12065,7 +12065,7 @@ basic_json_parser_66:
primitive. The original JSON value can be restored using the @ref
unflatten() function.
@return an object that maps JSON pointers to primitve values
@return an object that maps JSON pointers to primit
i
ve values
@note Empty objects and arrays are flattened to `null` and will not be
reconstructed correctly by the @ref unflatten() function.
...
...
@@ -12132,7 +12132,7 @@ basic_json_parser_66:
[JSON Patch](http://jsonpatch.com) defines a JSON document structure for
expressing a sequence of operations to apply to a JSON) document. With
this funcion, a JSON Patch is applied to the current JSON value by
this func
t
ion, a JSON Patch is applied to the current JSON value by
executing all operations from the patch.
@param[in] json_patch JSON patch document
...
...
@@ -12300,7 +12300,7 @@ basic_json_parser_66:
JSON_THROW
(
std
::
invalid_argument
(
"JSON patch must be an array of objects"
));
}
// iterate and apply th
e
operations
// iterate and apply th
e
operations
for
(
const
auto
&
val
:
json_patch
)
{
// wrapper to get a value for an operation
...
...
@@ -12439,8 +12439,8 @@ basic_json_parser_66:
@note Currently, only `remove`, `add`, and `replace` operations are
generated.
@param[in] source JSON value to copare from
@param[in] target JSON value to copare against
@param[in] source JSON value to co
m
pare from
@param[in] target JSON value to co
m
pare against
@param[in] path helper value to create JSON pointers
@return a JSON patch to convert the @a source to @a target
...
...
src/json.hpp.re2c
View file @
662a9b8f
...
...
@@ -1106,7 +1106,7 @@ class basic_json
/*!
@brief returns version information on the library
This function returns a JSON object with inf
i
ormation about the library,
This function returns a JSON object with information about the library,
including the version number and information on the platform and compiler.
@return JSON object holding version information
...
...
@@ -3417,7 +3417,7 @@ class basic_json
/*!
@brief get a reference value (implicit)
Implict reference access to the internally stored JSON value. No copies
Implic
i
t reference access to the internally stored JSON value. No copies
are made.
@warning Writing data to the referee of the result yields an undefined
...
...
@@ -3492,7 +3492,7 @@ class basic_json
template < typename ValueType, typename std::enable_if <
not std::is_pointer<ValueType>::value and
not std::is_same<ValueType, typename string_t::value_type>::value
#ifndef _MSC_VER // fix for issue #167 operator<< abiguity under VS2015
#ifndef _MSC_VER // fix for issue #167 operator<< a
m
biguity under VS2015
and not std::is_same<ValueType, std::initializer_list<typename string_t::value_type>>::value
#endif
, int >::type = 0 >
...
...
@@ -4285,7 +4285,7 @@ class basic_json
@complexity The complexity depends on the type:
- objects: amortized constant
- arrays: linear in distance between pos and the end of the container
- arrays: linear in distance between
@a
pos and the end of the container
- strings: linear in the length of the string
- other types: constant
...
...
@@ -5537,7 +5537,7 @@ class basic_json
@throw std::domain_error if @a pos is not an iterator of *this; example:
`"iterator does not fit current value"`
@complexity Constant plus linear in the distance between pos and end of
@complexity Constant plus linear in the distance between
@a
pos and end of
the container.
@liveexample{The example shows how `insert()` is used.,insert}
...
...
@@ -6234,7 +6234,7 @@ class basic_json
`std::setw(4)` on @a o sets the indentation level to `4` and the
serialization result is the same as calling `dump(4)`.
@note During serializaion, the locale and the precision of the output
@note During serializa
t
ion, the locale and the precision of the output
stream @a o are changed. The original values are restored when the
function returns.
...
...
@@ -9774,7 +9774,7 @@ class basic_json
if (m_stream == nullptr or m_stream->eof())
{
// m_start may or may not be pointing into m_line_buffer at
// this point. We trust the standa
n
d library to do the right
// this point. We trust the standa
r
d library to do the right
// thing. See http://stackoverflow.com/q/28142011/266378
m_line_buffer.assign(m_start, m_limit);
...
...
@@ -9862,7 +9862,7 @@ class basic_json
m_start + 1 + x < m_cursor - 1 must hold to loop indefinitely. This
can be rephrased to m_cursor - m_start - 2 > x. With the
precondition, we x <= 0, meaning that the loop condition holds
indefinitly if i is always decreased. However, observe that the value
indefinit
e
ly if i is always decreased. However, observe that the value
of i is strictly increasing with each iteration, as it is incremented
by 1 in the iteration expression and never decremented inside the loop
body. Hence, the loop condition will eventually be false which
...
...
@@ -9991,12 +9991,12 @@ class basic_json
/*!
@brief parse floating point number
This function (and its overloads) serves to select the most approprate
This function (and its overloads) serves to select the most appropr
i
ate
standard floating point number parsing function based on the type
supplied via the first parameter. Set this to @a
static_cast<number_float_t*>(nullptr).
@param[in,out] endptr rec
ie
ves a pointer to the first character after
@param[in,out] endptr rec
ei
ves a pointer to the first character after
the number
@return the floating point number
...
...
@@ -10009,12 +10009,12 @@ class basic_json
/*!
@brief parse floating point number
This function (and its overloads) serves to select the most approprate
This function (and its overloads) serves to select the most appropr
i
ate
standard floating point number parsing function based on the type
supplied via the first parameter. Set this to @a
static_cast<number_float_t*>(nullptr).
@param[in,out] endptr rec
ie
ves a pointer to the first character after
@param[in,out] endptr rec
ei
ves a pointer to the first character after
the number
@return the floating point number
...
...
@@ -10027,12 +10027,12 @@ class basic_json
/*!
@brief parse floating point number
This function (and its overloads) serves to select the most approprate
This function (and its overloads) serves to select the most appropr
i
ate
standard floating point number parsing function based on the type
supplied via the first parameter. Set this to @a
static_cast<number_float_t*>(nullptr).
@param[in,out] endptr rec
ie
ves a pointer to the first character after
@param[in,out] endptr rec
ei
ves a pointer to the first character after
the number
@return the floating point number
...
...
@@ -10075,7 +10075,7 @@ class basic_json
// maximum absolute value of the relevant integer type
number_unsigned_t max;
// temporarily store the type to avoid unecessary bitfield access
// temporarily store the type to avoid un
n
ecessary bitfield access
value_t type;
// look for sign
...
...
@@ -10708,7 +10708,7 @@ class basic_json
if (reference_token == "-")
{
// explicit
y
ly treat "-" as index beyond the end
// explicitly treat "-" as index beyond the end
ptr = &ptr->operator[](ptr->m_value.array->size());
}
else
...
...
@@ -11215,7 +11215,7 @@ class basic_json
primitive. The original JSON value can be restored using the @ref
unflatten() function.
@return an object that maps JSON pointers to primitve values
@return an object that maps JSON pointers to primit
i
ve values
@note Empty objects and arrays are flattened to `null` and will not be
reconstructed correctly by the @ref unflatten() function.
...
...
@@ -11282,7 +11282,7 @@ class basic_json
[JSON Patch](http://jsonpatch.com) defines a JSON document structure for
expressing a sequence of operations to apply to a JSON) document. With
this funcion, a JSON Patch is applied to the current JSON value by
this func
t
ion, a JSON Patch is applied to the current JSON value by
executing all operations from the patch.
@param[in] json_patch JSON patch document
...
...
@@ -11450,7 +11450,7 @@ class basic_json
JSON_THROW(std::invalid_argument("JSON patch must be an array of objects"));
}
// iterate and apply th
e
operations
// iterate and apply th
e
operations
for (const auto& val : json_patch)
{
// wrapper to get a value for an operation
...
...
@@ -11589,8 +11589,8 @@ class basic_json
@note Currently, only `remove`, `add`, and `replace` operations are
generated.
@param[in] source JSON value to copare from
@param[in] target JSON value to copare against
@param[in] source JSON value to co
m
pare from
@param[in] target JSON value to co
m
pare against
@param[in] path helper value to create JSON pointers
@return a JSON patch to convert the @a source to @a target
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment