962 Commits

Author SHA1 Message Date
Yuri Khan
8c182e51e7 Flatten allOf keyword violations 2017-09-30 20:16:03 +07:00
Yuri Khan
1f75402704 refactor Schema: Keep ErrorHandler reference in Context 2017-09-30 19:05:25 +07:00
KaitoHH
473553bd5a fix gcc & cl warning 2017-09-29 19:13:29 +08:00
KaitoHH
9394b84440 remove unnecessary code 2017-09-29 18:19:41 +08:00
KaitoHH
799fdea9fc add cursor wrapper 2017-09-29 15:26:24 +08:00
KaitoHH
143641c75a suppress C4512, C4702 warning 2017-09-29 15:26:18 +08:00
KaitoHH
79d9c71f98 fix stream wrapper initializer
fix initialization warning

add special wrapper for AutoUTFInputStream
2017-09-29 15:24:27 +08:00
KaitoHH
b16ff281f8 Add feature of locating line and column number of error 2017-09-29 15:24:27 +08:00
Yuri Khan
f716c3bfb5 Report schema violation details (#619) 2017-09-24 12:56:55 +07:00
Yuri Khan
c2371584a0 Keep schema URI in GenericSchemaDocument and internal::Schema 2017-09-23 21:36:07 +07:00
Yuri Khan
2bfd0cc6c7 internal::Schema: Keep pointer for future use 2017-09-23 20:42:39 +07:00
Christopher Warrington
a683902b2c Assert Type enum lower bound as well 2017-09-06 15:13:20 -07:00
Christopher Warrington
6e38649ec6 Guard against min/max being macros in document.h
Sometimes, particularly when Microsoft's windows.h is included, min/max
are defined as macros, interfering with use of
std::numeric_limits::min() and the like.

To guard against this, the function name is wrapped in an extra set of
parenthesis, which inhibits function-style macro expansion.
2017-09-05 18:26:47 -07:00
Minmin Gong
f91405801f Specifies the endian of msvc ARM64 configuration. 2017-08-31 23:16:59 -07:00
bluehero
f9004b90c5 modify 2017-08-07 13:09:22 +08:00
bluehero
c831675026 modify 2017-08-07 11:58:37 +08:00
bluehero
5fb06596a9 modify 2017-08-07 11:44:27 +08:00
bluehero
7c1f208253 modify 2017-08-05 16:53:45 +08:00
Milo Yip
c34e3dfc72 Merge pull request #1018 from miloyip/issue1017_allOfHandler
Fix #1017 allOf keyword fail with Writer handler
2017-07-13 16:57:56 +08:00
Milo Yip
fcd2e1f60c Fix #1017 allOf keyword fail with Writer handler
Gave up using static binding for null handler, because it cannot be
used with arbitrary handler type. Change `OutputHandler handler_` to
pointer type.
2017-07-13 16:07:36 +08:00
Philipp A. Hartmann
70171f9790 GenericStringRef: move assert out of expression 2017-07-10 22:32:18 +02:00
Milo Yip
f624a3037c Merge pull request #1010 from pah/fixes/817-stringref-null
Improve handling of NULL strings
2017-07-10 10:08:21 +08:00
Philipp A. Hartmann
47c3c1ec9f Improved handling of NULL strings
* Safely assert upon passing NULL string without length
   (requires usage of RAPIDJSON_ASSERT within an expression)
 * Allow using a NULL string together with an explicit length 0
   (GenericStringRef, GenericValue::SetString, ...), see #817
 * Add GenericValue::SetString(StringRefType, Allocator&) overload
 * Add tests for the various cases
2017-07-09 14:46:59 +02:00
Philipp A. Hartmann
14218aeb0a ParseResult: improve bool conversion and add operator!=
* Use safe-bool idiom for boolean conversion to avoid accidental
   misuse of ParseResult values (closes #989)
 * Add operator!= to support more comparison expressions
   (previously silently/erroneously used operator bool)
2017-07-09 11:13:31 +02:00
Milo Yip
2f45319b4e Merge pull request #968 from TomaszNo/icc-preprocessor-guard
Intel C++ Compiler preprocessor guard for #pragma intrinsic - diyfp.h
2017-06-28 11:36:55 +08:00
Milo Yip
df6362d450 Fix patternProperties & additionalProperties lead to ASSERT
Fix #825
2017-06-09 10:16:24 +08:00
Philipp A. Hartmann
68c96e987b Fixup #964 by forwarding copyConstStrings recursively
As reported by @Llerd in #962, the `copyConstStrings` parameter
has not been forwarded recursively to the constructors of
object members and array elements.
2017-05-27 10:26:35 +02:00
Tomasz Noczynski (Linux)
294ad93e30 To avoid Intel C++ Compiler #1879 warnings:
warning #1879: unimplemented pragma ignored: #pragma intrinsic(_BitScanReverse64)
warning #1879: unimplemented pragma ignored: #pragma intrinsic(_umul128)
2017-05-25 14:14:16 +02:00
Tomasz Noczynski (Linux)
77d2fadfb6 If storage class is not specified as first in declaration then Intel C++ Compiler 2017 generates message:
message #82: storage class is not first
2017-05-25 13:21:57 +02:00
Philipp A. Hartmann
4ef1ff4fba GenericValue::CopyFrom: add option to force copying of strings
Copying the result of an in-situ parsing into another value/document
currently requires that the original buffer - still holding the strings
from the parsing, outlives the  destination object as well.

In order to obtain a "full" copy of a GenericValue, this commit adds
an optional flag `copyConstStrings` to `CopyFrom`, which then forces
to take a copy of all embedded strings in the source value.

This solves the problem discussed in #962.
2017-05-18 19:11:04 +02:00
Hartwig
568107e178 Add convenience method Key(std::basic_string<Ch> const&) to Writer 2017-05-10 22:56:01 +02:00
Harry Wong
cba45fe9de Onley apply to GCC 7 2017-05-04 10:32:45 +08:00
Harry Wong
fe19b7b601 Supress implicit fallthrough in GCC 2017-05-04 10:08:48 +08:00
Milo Yip
b45c5408d1 Merge pull request #932 from JunHe77/master
Added ARM-Neon support for SIMD.SkipWhitespace*
2017-04-24 16:22:14 +08:00
Oliver Hahm
885b5cd2f9 common notation of empty if/else case 2017-04-21 14:49:30 +02:00
Oliver Hahm
63423eb6f8 fix return values 2017-04-21 14:49:12 +02:00
Alejandro Martinez
2291258bb8 Added ARM-Neon support for SIMD.SkipWhitespace*
Change-Id: Iaf210d029758723a7eeb7f28fc10cab7467889a9
Signed-off-by: Jun He <jun.he@arm.com>
2017-04-21 07:33:17 +00:00
Milo Yip
e6d7247ed9 Merge pull request #924 from lichray/fix-gcc7-warning
Fix a non-type template parameter type mismatch
2017-04-17 14:44:08 +08:00
Philipp A. Hartmann
f93a29bec2 RAPIDJSON_STATIC_ASSERT: use C++11 static_assert, if available 2017-04-14 20:19:16 +02:00
Zhihao Yuan
ec90588c72
Fix a non-type template parameter type mismatch
This issues a warning in gcc7.
2017-04-08 22:51:15 -05:00
Milo Yip
77f643dc51 Fix #910 incorrect casting 2017-04-07 10:23:30 +08:00
Milo Yip
5d9d0f78b5 Merge pull request #909 from miloyip/issue905_PrettyWriterWriteFlags
Fix #905 unable to set writeFlags for PrettyWriter
2017-03-27 18:26:17 +08:00
Milo Yip
d88be8ef16 Fix #905 unable to set writeFlags for PrettyWriter 2017-03-27 14:05:03 +08:00
Alejandro Martinez
85500e8c8f Changed error code for invalid special ascii chars, fixed writer tests 2017-03-24 13:37:23 +00:00
Alejandro Martinez
da4fd6794c Fixed bug on space hexadecimal encoding 2017-03-22 10:19:54 +00:00
Milo Yip
e5635fb27f Fix #899 2017-03-16 10:46:48 +08:00
Milo Yip
bba388b4fa Merge pull request #896 from StilesCrisis/writer-flush-api
Writer flush api
2017-03-16 10:36:25 +08:00
Milo Yip
465fab45c1 Merge pull request #897 from StilesCrisis/issue-889-pretty-writer
Issue 889 pretty writer
2017-03-16 10:35:26 +08:00
John Stiles
d5d18cf694 Fix template length optimization issue in PrettyWriter
Missed PrettyWriter in the initial fix for Issue #889
2017-03-14 23:48:41 -07:00
John Stiles
31c6c50ac6 Provide a Flush() API within Writer
This is helpful if you’re writing code that needs to control flush
behavior and you don’t want to pass around your buffer object to each
handler function alongside the writer. Seems like an easy convenience
to add.
2017-03-14 23:28:59 -07:00