mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-06 13:37:25 +00:00
Parser now allows empty tables in JSON
Bug: 16870719 Change-Id: Ia5fdce49a67b1aa621ab1e37a815e2a3293257b6 Tested: on Linux
This commit is contained in:
@@ -420,7 +420,7 @@ void Parser::SerializeStruct(const StructDef &struct_def, const Value &val) {
|
||||
uoffset_t Parser::ParseTable(const StructDef &struct_def) {
|
||||
Expect('{');
|
||||
size_t fieldn = 0;
|
||||
for (;;) {
|
||||
if (!IsNext('}')) for (;;) {
|
||||
std::string name = attribute_;
|
||||
if (!IsNext(kTokenStringConstant)) Expect(kTokenIdentifier);
|
||||
auto field = struct_def.fields.Lookup(name);
|
||||
|
||||
Reference in New Issue
Block a user