mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-05 21:17:25 +00:00
serialize boolean in JSON to "true/false" instead of "0/1"
Change-Id: I90cf519c00eaf9ccd9fcab8035a91b9205587c3b
This commit is contained in:
committed by
Wouter van Oortmerssen
parent
44261ccdf1
commit
5de28c74f9
@@ -635,6 +635,11 @@ void FuzzTest2() {
|
||||
Dummy();
|
||||
}
|
||||
break;
|
||||
case flatbuffers::BASE_TYPE_BOOL:
|
||||
AddToSchemaAndInstances("bool", deprecated
|
||||
? ""
|
||||
: (lcg_rand() % 2 ? "true" : "false"));
|
||||
break;
|
||||
default:
|
||||
// All the scalar types.
|
||||
schema += flatbuffers::kTypeNames[base_type];
|
||||
|
||||
Reference in New Issue
Block a user