mirror of
https://github.com/google/flatbuffers.git
synced 2026-07-02 01:23:59 +00:00
committed by
Wouter van Oortmerssen
parent
88912640d0
commit
8e42f44807
@@ -2047,7 +2047,7 @@ class CppGenerator : public BaseGenerator {
|
|||||||
auto cpp_type = field.attributes.Lookup("cpp_type");
|
auto cpp_type = field.attributes.Lookup("cpp_type");
|
||||||
std::string indexing;
|
std::string indexing;
|
||||||
if (field.value.type.enum_def) {
|
if (field.value.type.enum_def) {
|
||||||
indexing += "(" + field.value.type.enum_def->name + ")";
|
indexing += "(" + WrapInNameSpace(*field.value.type.enum_def) + ")";
|
||||||
}
|
}
|
||||||
indexing += "_e->Get(_i)";
|
indexing += "_e->Get(_i)";
|
||||||
if (field.value.type.element == BASE_TYPE_BOOL) { indexing += " != 0"; }
|
if (field.value.type.element == BASE_TYPE_BOOL) { indexing += " != 0"; }
|
||||||
|
|||||||
Reference in New Issue
Block a user