Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
yaomer committed Sep 20, 2022
1 parent 9bd4e1e commit 212bd92
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ int main()
jv.append("A").append("B").append("C"); // true
jv.at(0) = "hello"; // modify, ok

json::value jv1
json::value jv1;
jv1.at(0) = "A"; // false
}
```
3 changes: 2 additions & 1 deletion json.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,9 @@ class value {
// JSON Array
typedef std::vector<value_ptr> array;
typedef std::unique_ptr<array> array_ptr;
public:
// Saved Value
typedef std::variant<string, number, object_ptr, array_ptr> union_value;
public:
value() : type(Null) { }
value(const value&) = delete;
value& operator=(const value&) = delete;
Expand Down

0 comments on commit 212bd92

Please sign in to comment.