2442 Commits

Author SHA1 Message Date
Steve Hanson
1ce516e50b Suppress uritest 2023-01-05 20:34:07 +08:00
Steve Hanson
778dc8b03e fix #1 2023-01-05 20:34:07 +08:00
Tana0910
76281ff388 fix a typo in error.h: literial -> literal 2023-01-04 17:45:39 +08:00
Kent Ross
a98e99992b do not define operator!= in C++20
A change to the semantics of equality operator rewriting in C++20 (P2468R2: The Equality Operator You Are Looking For) means that operator== may not be rewritten with reversed operands if operator!= is also defined. Since operator!= can normally be synthesized from operator== regardless in this language standard, we can and should avoid defining those when the new language semantics are available.

This fixes the compilation of tests (and probably consuming code) in C++20 onwards for compilers that implement this new semantic, including recent nightly builds of clang-16.

Reference: https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2022/p2468r2.html
2022-12-19 05:30:49 +08:00
Steve Hanson
b08672d469 review comment updates 2022-12-19 05:30:00 +08:00
Steve Hanson
55eca66f39 code & tests for openapi 2.0 & 3.0 suppprt 2022-12-19 05:30:00 +08:00
Steve Hanson
80b6d1c834 small corrections for schema.h 2022-12-01 00:42:44 +08:00
Steve Hanson
97fd830175 attempt to fix SEH 2022-12-01 00:42:44 +08:00
Steve Hanson
7cad78e236 tidy up after merge from master 2022-12-01 00:42:44 +08:00
Steve Hanson
794248ee62 fix build break 2022-12-01 00:42:44 +08:00
Steve Hanson
2d87923e91 remove unnecessary templating from schema tests 2022-12-01 00:42:44 +08:00
Steve Hanson
aa1f22251f correct address.json so tests pass 2022-12-01 00:42:44 +08:00
Steve Hanson
ecb8d9e3a0 add dump of unexpected schema errors in schematest.cpp 2022-12-01 00:42:44 +08:00
Steve Hanson
89f6717f0b corrections 2022-12-01 00:42:44 +08:00
Steve Hanson
338d8defdb initial 2022-12-01 00:42:44 +08:00
jwillcox-telework
06d58b9e84 Update dtoa.h
Fixed DigitGen to use proper suffix for uint64_t numeric types. Change from U suffix to ULL suffix.

On SLED 11.0 compiler, code would not compile.

cd rapidjson-master
g++ -Wall -m32 -ggdb -Iinclude -O1 ./example/simpledom/simpledom.cpp -o simpledom 2>&1 | tee out.txt
2022-08-23 10:52:40 +08:00
jwillcox-telework
22a62fcc2c Update allocators.h
Fixing compiler error on older compilers, such as SLED 11.0.

cd rapidjson-master
g++ -Wall -m32 -ggdb -Iinclude -O1 ./example/simpledom/simpledom.cpp -o simpledom 2>&1 | tee out.txt

Changed SIZE_MAX to std::numeric_limits<size_t>::max() in code to get rid of SIZE_MAX error.
2022-08-23 10:52:40 +08:00
Tim Gates
27c3a8dc0e docs: fix simple typo, perecent -> percent
There is a small typo in test/unittest/pointertest.cpp.

Should read `percent` rather than `perecent`.

Signed-off-by: Tim Gates <tim.gates@iress.com>
2022-07-20 21:53:57 +08:00
Kent Ross
232389d4f1 delete unused variable 2022-05-24 10:03:13 +08:00
Kent Ross
64faab2e92 gate definition of symmetric equality operators on impl, not lib
These operators call themselves recursively if C++20 semantics are present in the compiler, regardless of standard library support for the operator; therefore the test should be on __cpp_impl_three_way_comparison, not __cpp_lib_[...].

This fixes the Value.EqualtoOperator test when the language standard is set to C++20 and the standard library does not yet define the library support macro.
2022-05-24 10:03:13 +08:00
Johnny Shaw
719304b113 fixes for natvis 2022-05-21 15:02:39 +08:00
Johnny Shaw
dd3f730d74 Make schema dtor robust against exceptions 2022-05-21 09:35:41 +08:00
Peter Kasting
781a4e667d Try to fix MSVC build. 2022-05-19 11:55:17 +08:00
Peter Kasting
88f8ddd70c Include conceptual change from PR 2001. 2022-05-19 11:55:17 +08:00
Peter Kasting
4695953567 Avoid exit-time destructors.
operator[]() was recently changed to use the existing code in order to
correctly align the returned pointer; however this broke
-Wexit-time-destructors.  Change to a method that is still correctly
aligned but does not generate a destructor.
2022-05-19 11:55:17 +08:00
Peter Kasting
0390b1ad57 Avoid exit-time destructors.
operator[]() was recently changed to use the existing code in order to
correctly align the returned pointer; however this broke
-Wexit-time-destructors.  Change to a method that is still correctly
aligned but does not generate a destructor.
2022-05-19 11:55:17 +08:00
Tom Briden
2b2c804500 encdedstreamtest: fix use-after-free compile error with gcc-12 2022-05-16 10:23:11 +08:00
Tom Briden
1f59c69cd1 valuetest: fix potential write of terminating nul past the end of the destination
Fixes 2 compile errors with gcc-12, eg:

tesunittest/valuetest.cpp:1516:30: error: 'sprintf' may write a terminating nul past the end of the destination [-Werror=format-overflow=]
test/unittest/valuetest.cpp:1516:20: note: 'sprintf' output between 2 and 11 bytes into a destination of size 10
2022-05-16 10:23:11 +08:00
Milo Yip
fcb23c2dbf
Merge pull request #2008 from agate-pris/access-to-allocator-types
Access to allocator types
2022-04-06 12:28:13 +08:00
Milo Yip
bdc49ad80a
Merge pull request #2014 from lazydroid/dev/lenik/fix_shadowed_variables
fix shadowed variable
2022-04-06 12:27:10 +08:00
Leonid Terenin
6b500986c4 fix shadowed variable, take 2 2022-04-06 10:42:40 +09:00
Leonid Terenin
3988c5e25e fix shadowed variable 2022-04-06 09:58:56 +09:00
agate-pris
386d31ab69 Allow access to the template parameter StackAllocator in the GenericDocument
Add the typedef declaration `StackAllocatorType` to the class template
`GenericDocument`. This allows the user to access the template parameter
`StackAllocator`.
2022-03-18 19:34:11 +09:00
agate-pris
79d7a448e9 Allow the macro RAPIDJSON_DEFAULT_STACK_ALLOCATOR to be used in any namespace
RAPIDJSON_DEFAULT_STACK_ALLOCATOR uses names in the namespace
`RAPIDJSON_NAMESPACE`. Replace this with a name starting in the global
namespace.
2022-03-18 19:32:01 +09:00
agate-pris
9965ab37f6 Allow the macro RAPIDJSON_DEFAULT_ALLOCATOR to be used in any namespace
`RAPIDJSON_DEFAULT_ALLOCATOR` uses names in the namespace
`RAPIDJSON_NAMESPACE`. Replace this with a name starting in the global
namespace.
2022-03-18 19:22:19 +09:00
Milo Yip
8261c1ddf4
Merge pull request #1969 from MalcolmTyrrell/MalcolmTyrrell/sanitizeSchemaCode
Sanitize the code in schema.h
2022-03-09 12:15:45 +08:00
Milo Yip
0d78b1ce93
Merge pull request #1989 from adamcalhoon/really-fix-placement-new-alignment
Fix the alignment of placement new buffer for GenericValue.
2022-03-08 17:09:47 +08:00
Adam Calhoon
1dff2abff7 Fix the alignment of placement new buffer for GenericValue.
When using operator[] on a GenericValue type clang-tidy complains,
appropriately, about the alignment of the buffer used for placement-new
of the "dummy" GenericValue.
2022-02-08 22:29:15 -05:00
Milo Yip
e4bde97744
Merge pull request #1988 from Tencent/revert-1987-fix-placement-new-alignment
Revert "Fix the alignment of placement new buffer for GenericValue."
2022-02-09 10:48:22 +08:00
Milo Yip
88bbd87ddd
Revert "Fix the alignment of placement new buffer for GenericValue." 2022-02-09 10:48:05 +08:00
Milo Yip
bf8ca5da88
Merge pull request #1987 from adamcalhoon/fix-placement-new-alignment
Fix the alignment of placement new buffer for GenericValue.
2022-02-09 10:47:25 +08:00
Adam Calhoon
5b242b6b2d Fix the alignment of placement new buffer for GenericValue.
When using operator[] on a GenericValue type clang-tidy complains,
appropriately, about the alignment of the buffer used for placement-new
of the "dummy" GenericValue.
2022-02-08 12:03:02 -05:00
Milo Yip
fd3dc29a5c
Merge pull request #1944 from ilelann/patch-1
Support CMake none targets
2021-11-24 23:11:45 +08:00
Malcolm Tyrrell
53602ec6bb Sanitize the code in schema.h 2021-11-17 09:31:22 +00:00
Milo Yip
0d4517f15a
Merge pull request #1961 from jedwardsol/issue1960_arm64ec_intrinsic
use softintrin on arm64ec
2021-10-31 11:07:57 +08:00
jedwards
060c348ea0 use softintrin on arm64ec 2021-10-29 15:31:10 -07:00
Milo Yip
4d6cb08189
Merge pull request #1949 from ardb-uk/master
Resolving issue #1948
2021-10-15 14:34:41 +08:00
ardb-uk
033bef3c6c
Merge pull request #1 from ardb-uk/ardb-uk-patch-1
Resolve issue 1948
2021-10-12 16:33:03 +01:00
ardb-uk
befba39afc
Merge pull request #2 from ardb-uk/ardb-uk-patch-1-1
Resolved issue #1948
2021-10-12 16:32:28 +01:00
ardb-uk
4bbaf28ffc
Add files via upload 2021-10-12 16:23:44 +01:00