631 Commits

Author SHA1 Message Date
Philipp A. Hartmann
d84c051564 jsoncheckertest: add checks for iterative parser as well 2014-08-11 17:15:07 +02:00
Philipp A. Hartmann
834109557d readertest.cpp: use CRTP to activate "ADD_FAILURE()" calls in handlers 2014-08-11 17:15:07 +02:00
Philipp A. Hartmann
3755470f0f BaseReaderHandler: allow overriding of Default() implementation
By adding an optional CRTP template parameter, the BaseReaderHandler
can call the "overridden" `Default()` function from the `Derived`
class.

See https://en.wikipedia.org/wiki/Curiously_recurring_template_pattern
2014-08-11 17:15:07 +02:00
Philipp A. Hartmann
e29a4521b1 readertest.cpp: use top-level Parse functions, instead of internal ones
With the allowance of arbitrary root value types, the individual tests
can use the top-level Parse functions, instead of ParseFoo() variants.

Secondly, some unneeded array wrappers have been dropped and non-singular
tests starting with other values than objects or arrays have been added.
2014-08-11 17:14:31 +02:00
Philipp A. Hartmann
24b7976145 tutorial.md: lift restriction to object/array root values 2014-08-11 17:14:31 +02:00
Philipp A. Hartmann
4d031d054a readme.md: reference RFC7159 instead of RFC4627 2014-08-11 17:14:31 +02:00
Philipp A. Hartmann
89793599ce error/{en,error}.h: drop unused kParseErrorDocumentRootNotObjectOrArray error 2014-08-11 17:14:31 +02:00
Philipp A. Hartmann
c256752668 readertest: drop object/array root restriction tests 2014-08-11 17:14:31 +02:00
Philipp A. Hartmann
e45557e28e writertest: add some roundtrip tests for non-compound root values 2014-08-11 17:14:31 +02:00
Philipp A. Hartmann
c0c0c398b6 jsoncheckertest: skip "fail1.json", as it is now accepted by RapidJSON 2014-08-11 17:14:31 +02:00
Philipp A. Hartmann
c9f2715115 Reader: drop object/array root restrction from iterative parser 2014-08-11 17:14:31 +02:00
Philipp A. Hartmann
edccda00bd drop object/array root restriction from recursive parser 2014-08-11 17:14:31 +02:00
Philipp A. Hartmann
8d53689432 (Pretty)Writer: drop restriction to object/array roots 2014-08-11 17:14:31 +02:00
Philipp A. Hartmann
fc1e956a0c fix sign-comparison warning/error 2014-08-11 16:57:23 +02:00
Milo Yip
86245ce97a Remove cppformat and strtk 2014-08-11 22:40:13 +08:00
Milo Yip
0dbcc1cf2e Add license and change indents from tab to space. 2014-08-11 22:26:45 +08:00
Milo Yip
adb3974e4d Merge pull request #97 from miloyip/issue72customdtoa
Fix #72
2014-08-11 21:56:10 +08:00
Milo Yip
34dd0fd68f Merge pull request #99 from pah/travis-ci
travis-doxygen.sh: only overwrite .git-credentials, iff not exists
2014-08-11 16:11:41 +08:00
Milo Yip
c54915297b Change CountDecimalDigit32() to simple implementation
It is simple and pure C++. And it is found in performance test that it
is even faster than the original version, due to distribution of n. But
the performance gain is not obvious in RapidJSON.
2014-08-11 00:30:31 +08:00
Milo Yip
3b3600b3d6 Update internals.md
typo
2014-08-10 23:14:30 +08:00
Milo Yip
8969549527 Update internals.md 2014-08-10 23:00:49 +08:00
Milo Yip
bb748364fe Re-layout iterative parser state diagram. 2014-08-10 22:54:14 +08:00
Milo Yip
54a615a8a3 Added rapidjson logo 2014-08-10 21:32:12 +08:00
Milo Yip
1900b7bace Remove double precision settings API in Writer 2014-08-09 21:37:02 +08:00
Milo Yip
0d915644a4 Fixed gcc effc++ warning in dtoa.h 2014-08-09 21:27:32 +08:00
Milo Yip
a7762a3453 Custom dtoa() impleemntation
Modified from Milo's Grisu2 implementation. 99.9% cases return shortest
decimal format.
2014-08-09 21:12:58 +08:00
Milo Yip
6978778884 Change double parsing with fast-path conversion
Accurate rounding in normal numerical ranges, also reduce lookup table
size.
2014-08-09 21:11:37 +08:00
Milo Yip
f0955d327c Fixed a bug in perftest (was asserted in debug) 2014-08-09 20:35:48 +08:00
Milo Yip
0e4f08ea89 Fix a compilation error due to INT64_C 2014-08-08 22:07:02 +08:00
Milo Yip
5e5fb7b3d8 Change UINT64_C() to RAPIDJSON_UINT64_C2()
Fix #94
2014-08-08 21:34:43 +08:00
Milo Yip
41dde39bbc Merge pull request #96 from miloyip/issue91removeelement
Fix #91
2014-08-08 20:42:55 +08:00
Milo Yip
67143c2ba0 Merge pull request #93 from pah/fixes/86-gtest-werror
premake.lua: relax warnings for GTest and perftest (fixes #86)
2014-08-01 09:31:51 +08:00
Philipp A. Hartmann
5ecf7f50ed premake.lua: relax warnings for GTest and perftest (fixes #86)
For the "test" solution, the "gtest" and "perftest" projects contain
third-party code.  Relax the warning settings for "gmake" for these
projects to avoid build failures due to third-party code.
2014-07-31 21:12:45 +02:00
Milo Yip
2f9544620b Add UINT64_C() macros for 64-bit integer literals in u64toa() 2014-08-01 00:25:56 +08:00
Milo Yip
b52e07822e Try to add erase-remove idiom in unit test but fail to compile on VC2013. 2014-08-01 00:04:31 +08:00
Milo Yip
c3ad232c3e Fixes size type in Value::operator==() 2014-08-01 00:01:06 +08:00
Milo Yip
9892847021 Update documents about erase member/elements, also added some time complexity information. 2014-07-31 23:58:52 +08:00
Milo Yip
10098319fe Merge pull request #92 from pah/issue91removeelement
Remove for object members, some cleanups for values
2014-07-31 19:19:44 +08:00
Philipp A. Hartmann
fc6d7a59dc GenericValue: rename Erase(ConstMemberIterator) to EraseMember 2014-07-31 13:16:56 +02:00
miloyip
afe59a0db1 Makes StringEqual() more safe by always compares lengths. 2014-07-31 19:08:37 +08:00
Philipp A. Hartmann
82b32a93d2 fix missing bracket 2014-07-31 13:06:28 +02:00
Philipp A. Hartmann
b98852e165 GenericValue: add tests for Erase(ConstMemberIterator[, ConstMemberIterator]) 2014-07-31 13:03:51 +02:00
Philipp A. Hartmann
96af95c945 GenericValue: add Erase function for object members 2014-07-31 13:03:32 +02:00
Philipp A. Hartmann
c0fcdcc478 GenericValue: use generated assignment/destructor for GenericMember 2014-07-31 13:03:32 +02:00
Philipp A. Hartmann
59fee54f9d GenericValue::Erase: pass ConstValueIterators 2014-07-31 13:03:32 +02:00
Philipp A. Hartmann
9a9c6d6810 GenericValue: improve Erase documentation 2014-07-31 13:03:32 +02:00
Philipp A. Hartmann
6ed9934143 GenericValue: document Array iterator functions 2014-07-31 13:03:32 +02:00
Philipp A. Hartmann
11d31aaa7b fix typo 2014-07-31 13:03:32 +02:00
miloyip
71ae5660ed Revert "Add Erase(ConstValueIterator) and Erase(ConstValueIterator,ConstValueIterator)"
This reverts commit 9ab2621e855a9abb8377520b42d6dfddcd49a8e1.
2014-07-31 18:56:57 +08:00
miloyip
9ab2621e85 Add Erase(ConstValueIterator) and Erase(ConstValueIterator,ConstValueIterator)
As std::vector::erase() overloads added in C++11
2014-07-31 18:53:17 +08:00