...
1#[ TableA
2 Automatically generated by the FlatBuffers compiler, do not modify.
3 Or modify. I'm a message, not a cop.
4
5 flatc version: 23.5.26
6
7 Declared by :
8 Rooting type : MyGame.Example.Monster ()
9]#
10
11import MyGame/OtherNameSpace/TableB as MyGame_OtherNameSpace_TableB
12import flatbuffers
13import std/options
14
15type TableA* = object of FlatObj
16func b*(self: TableA): Option[MyGame_OtherNameSpace_TableB.TableB] =
17 let o = self.tab.Offset(4)
18 if o != 0:
19 return some(MyGame_OtherNameSpace_TableB.TableB(tab: Vtable(Bytes: self.tab.Bytes, Pos: self.tab.Pos + o)))
20proc TableAstart*(builder: var Builder) =
21 builder.StartObject(1)
22proc TableAaddb*(builder: var Builder, b: uoffset) =
23 builder.PrependStructSlot(0, b, default(uoffset))
24proc TableAend*(builder: var Builder): uoffset =
25 return builder.EndObject()
View as plain text