Skip to content

Commit

Permalink
Fix amount of entries in the json object
Browse files Browse the repository at this point in the history
After the initial j.push_back() calls there is another j.emplace_back() call that makes the size == 4 not 3.
  • Loading branch information
abbaswasim authored Mar 2, 2021
1 parent 176d8e2 commit ddbdb65
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -580,7 +580,7 @@ bool foo = j.at(2);
j == "[\"foo\", 42, true, 1.78]"_json; // true
// other stuff
j.size(); // 3 entries
j.size(); // 4 entries
j.empty(); // false
j.type(); // json::value_t::array
j.clear(); // the array is empty again
Expand Down

0 comments on commit ddbdb65

Please sign in to comment.