You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 26, 2020. It is now read-only.
The copy constructor in json11.h is like this : "const Value & operator[](size_t i) const"
So user can not update an array by "[]", for example : obj["array"][0] = a_json_value;
Why is it designed like this?
The text was updated successfully, but these errors were encountered:
The Json type is intended to be an immutable value type, which has a number of advantages including thread safety and the ability to share data across copies. If you want a mutable array you can use a Json::array (which is just a typedef for a vector) and mutate it freely before putting it into a Json object.
The copy constructor in json11.h is like this : "const Value & operator[](size_t i) const"
So user can not update an array by "[]", for example : obj["array"][0] = a_json_value;
Why is it designed like this?
The text was updated successfully, but these errors were encountered: