diff --git a/include/flatbuffers/minireflect.h b/include/flatbuffers/minireflect.h index 5fe16a4a9..ff14e3aa6 100644 --- a/include/flatbuffers/minireflect.h +++ b/include/flatbuffers/minireflect.h @@ -360,15 +360,15 @@ struct ToStringVisitor : public IterationVisitor { void Unknown(const uint8_t *) { s += "(?)"; } void StartVector() { s += "["; + s += d; if (vector_delimited) { - s += d; indent_level++; append_indent(); } } void EndVector() { + s += d; if (vector_delimited) { - s += d; indent_level--; append_indent(); } @@ -378,8 +378,8 @@ struct ToStringVisitor : public IterationVisitor { const TypeTable * /*type_table*/, const uint8_t * /*val*/) { if (i) { s += ","; + s += d; if (vector_delimited) { - s += d; append_indent(); } }