Releases: open-source-parsers/jsoncpp
Minor bug-fix
- Bug-fix for
ValueIterator::operator-()(issue #169)
new feature in CharReaderBuilder: failIfExtra
This setting tells the Reader to fail (return false) if there is extra non-whitespace after a properly parsed JSON value. It catches mistakes like this (missing initial {):
"key" : "value" }
which would otherwise be interpretted as simply
"key"
failIfExtra is available by itself, and is also added for strictMode().
new feature in CharReaderBuilder: failIfExtra
This setting tells the Reader to fail (return false) if there is extra non-whitespace after a properly parsed JSON value. It catches mistakes like this (missing initial {):
"key" : "value" }
which would otherwise be interpretted as simply
"key"
failIfExtra is available by itself, and is also added for strictMode().
Builders and security fix
- Added
CharReaderBuilderandStreamWriterBuilder- See Advanced Usage in our docs.
- These allow consistent configuration of
CharReaderandStreamWriterfor users who require customization. - They will also let us add new features without breaking binary-compatibility.
- If you are using
operator<<(ostream, Json::Value)andoperator>>(istream, Json::Value), you will not notice a change. - The old
Readerand oldWritersare deprecated, but still maintained.
- Fixed security hole.
- A deeply-nested JSON input could cause a seg-fault.
- The fix is imperfect. Please stop using the deprecated classes.
- Minor bug-fixes and enhancements, including:
-Wall -Wextra -pedanticfor gcc- Minor formatting improvements, mainly to the deprecated
StyledStreamWriter(which was the default foroperator<<(ostream, Value).
- Reverted C++11 features.
- We still use C++11 in cmake, but we are rebasing the
v0.8.zbranch (which is binary-compatible with the ancient sourceforge0.6.0-rc2release) in order to provide all the bug-fixes possible. - Going forward, we intend to follow the Apache versioning model for functional-, source-, and binary-compatibility.
- We still use C++11 in cmake, but we are rebasing the
Binary-compatible w/ 0.6.0-rc2; includes most fixes from 1.4.0
- This release is binary-compatible with
0.6.0-rc2, but not with0.7.z, which was a mistaken release. This includes the major bug-fixes and enhancements from that and from1.4.z. 0.8.zreleases are based on the v0.8.z branch.0.y.zreleases continue to use fairly old compilers. Unlike1.4+.z, they do not require C++11.- Binary-compatiblility was checked both by careful diffing and by dynamically loading the new version into
test_lib_jsoncompiled against0.6.0-rc2. The handful of old test-failures relate to our relaxed type-checking and type-conversions, which will not matter for typical use-cases. E.g.
* Detail of ValueTest/isInt test failure:
src/test_lib_json/main.cpp(167): checkIs( integer_, checks )
src/test_lib_json/main.cpp(249): check.isDouble_ == value.isDouble()
Expected: false
Actual : true
src/test_lib_json/main.cpp(251): check.isUInt_ == value.isUInt()
Expected: false
Actual : true
- Of course, current tests all pass.
C++11
Bug-fix: Copy comments in `operator=()`
Changed operator=() to copy (and over-write) comments. This was probably expected by most users and is thus more like a bug-fix, but it could break some unit-tests. There is no performance penalty because the comments were already copied into an intermediate Value.
Print doubles as `%.17g`
Fix Solaris and older gcc
DEPRECATED
Cherry-picked from master branch.
Please switch to 0.8.z or 1.4.z.
Maintenance branch
DEPRECATED
This is compatible with the old 0.6.0rc2, but not binary compatible. Please switch to 0.8.z or 1.4.z.