[C++] Add ParseJson(), Parser(Parser&&), update fuzzers (#6284)

- add a new method ParseJson to minimize failures during fuzzing
- add default (conditional) move-constructor for Parser
- add a new monster_fuzzer
- switch fuzzers to C++17 and `test/cpp17` generated code
This commit is contained in:
Vladimir Glavnyy
2020-11-24 01:17:44 +07:00
committed by GitHub
parent bc518a5127
commit c27bc2d76f
16 changed files with 410 additions and 41 deletions

View File

@@ -0,0 +1,101 @@
"struct"
"table"
"enum"
"union"
"include"
"namespace"
"attribute"
"null"
"NULL"
"byte"
"int8"
"ubyte"
"uint8"
"bool"
"short"
"int16"
"ushort"
"uint16"
"int"
"int32"
"uint"
"uint32"
"float"
"float32"
"long"
"int64"
"ulong"
"uint64"
"double"
"float64"
"root_type"
"file_identifier"
"file_extension"
"{"
"}"
"["
"]"
"\""
"'"
"\\"
"//"
":"
","
" "
"\\n"
"\\r"
"/*"
"*/"
"true"
"false"
"null"
"\\u"
"\\b"
"\\f"
"\\t"
"."
"e"
"e+"
"e-"
"E"
"E+"
"E-"
"0x"
"p"
"a"
"b"
"Monster"
"pos"
"hp"
"name"
"weapons"
"damage"
"equipped_type"
"equipped"
"inventory"
"vector_of_longs"
"vector_of_doubles"
"test_type"
"test"
"test1"
"test2"
"test4"
"test3"
"test5"
"enemy"
"Weapon"
"Green"
"Red"
"Blue"
"testarrayofstring"
"testarrayofbools"
"testbool"
"testhashs32_fnv1"
"testhashu32_fnv1"
"testhashs64_fnv1"
"testhashu64_fnv1"
"testhashs32_fnv1a"
"testhashu32_fnv1a"
"testhashs64_fnv1a"
"testhashu64_fnv1a"
"flex"