Optionally generate type prefixes and suffixes for python code (#7857)

* optionally generate type prefixes and suffixes for python code

* fix codegen error when qualified name is empty

* generated code updated
This commit is contained in:
Max Burke
2023-04-25 21:38:16 -07:00
committed by GitHub
parent 3fda20d7c7
commit 56ecc1f548
29 changed files with 1568 additions and 454 deletions

View File

@@ -31,16 +31,25 @@ class TestSimpleTableWithEnum(object):
return self._tab.Get(flatbuffers.number_types.Uint8Flags, o + self._tab.Pos)
return 2
def TestSimpleTableWithEnumStart(builder): builder.StartObject(1)
def TestSimpleTableWithEnumStart(builder):
return builder.StartObject(1)
def Start(builder):
return TestSimpleTableWithEnumStart(builder)
def TestSimpleTableWithEnumAddColor(builder, color): builder.PrependUint8Slot(0, color, 2)
def TestSimpleTableWithEnumAddColor(builder, color):
return builder.PrependUint8Slot(0, color, 2)
def AddColor(builder, color):
return TestSimpleTableWithEnumAddColor(builder, color)
def TestSimpleTableWithEnumEnd(builder): return builder.EndObject()
def TestSimpleTableWithEnumEnd(builder):
return builder.EndObject()
def End(builder):
return TestSimpleTableWithEnumEnd(builder)
class TestSimpleTableWithEnumT(object):
# TestSimpleTableWithEnumT