mirror of
https://github.com/matrix-construct/construct
synced 2025-03-13 21:10:32 +01:00
ircd::json: Minor comment cleanup.
This commit is contained in:
parent
7f92c1243c
commit
121670d1a8
2 changed files with 8 additions and 9 deletions
|
@ -30,9 +30,9 @@ namespace json {
|
|||
// ircd::json::object and that is important to note here: iterating this array
|
||||
// by incrementing your own numerical index and making calls into this object
|
||||
// is NOT efficient. Simply put, do not do something like
|
||||
// `for(int x=0;x<array.count();x++) array.at(x)` as that will parse the array
|
||||
// from the beginning on every single iteration. Instead, use the provided
|
||||
// iterator object.
|
||||
// `for(int x=0; x<array.count(); x++) array.at(x)` as that will parse the
|
||||
// array from the beginning on every single iteration. Instead, use the
|
||||
// provided iterator object.
|
||||
//
|
||||
struct array
|
||||
:string_view
|
||||
|
|
|
@ -32,12 +32,11 @@
|
|||
//
|
||||
// Create and use a tuple to efficiently extract members from a json::object.
|
||||
// The tuple will populate its own members during a single-pass iteration of
|
||||
// the JSON input. This is cheap, because no copies or allocations or searches
|
||||
// are required to take place. If the JSON does not contain a member specified
|
||||
// in the tuple, the value will be default initialized. If the JSON contains
|
||||
// a member not specified in the tuple, it is ignored. If you need to know all
|
||||
// of the members specified in the JSON dynamically, use a json::index or
|
||||
// iterate manually.
|
||||
// the JSON input. If the JSON does not contain a member specified in the
|
||||
// tuple, the value will be default initialized. If the JSON contains a member
|
||||
// not specified in the tuple, it is ignored. If you need to know all of the
|
||||
// members specified in the JSON dynamically, use a json::index or iterate
|
||||
// manually.
|
||||
//
|
||||
namespace ircd {
|
||||
namespace json {
|
||||
|
|
Loading…
Add table
Reference in a new issue