fixed #31: only use spaces in pretty print

This commit is contained in:
Niels committed 2015-01-18 10:58:48 +01:00
1 parent b30e9ee5f4
commit 7724d34741
4 files changed
+13 -13

No files matched your search

+1 -3
View File
@@ -132,7 +132,7 @@ You can also get a string representation (serialize):
```cpp
// explicit conversion to string
std::string s = j.dump(); // {\"happy\": true, \"pi\": 3.141}
std::string s = j.dump(); // {\"happy\":true,\"pi\":3.141}
// serialization with pretty printing
std::cout << j.dump(4) << std::endl;
@@ -142,8 +142,6 @@ std::cout << j.dump(4) << std::endl;
// }
```
The value of s could be `{"pi": 3.141, "happy": true}`, but the order of the entries in the object is not fixed.
You can also use streams to serialize and deserialize:
```cpp