mirror of
https://github.com/google/flatbuffers.git
synced 2026-07-04 06:54:13 +00:00
Use enum types in generated read/mutate methods for Go (#4978)
This commit is contained in:
committed by
Wouter van Oortmerssen
parent
7c3c027295
commit
a4c362a1ba
@@ -156,6 +156,10 @@ func CheckReadBuffer(buf []byte, offset flatbuffers.UOffsetT, fail func(string,
|
||||
fail(FailString("name", "MyMonster", got))
|
||||
}
|
||||
|
||||
if got := monster.Color(); example.ColorBlue != got {
|
||||
fail(FailString("color", example.ColorBlue, got))
|
||||
}
|
||||
|
||||
// initialize a Vec3 from Pos()
|
||||
vec := new(example.Vec3)
|
||||
vec = monster.Pos(vec)
|
||||
|
||||
Reference in New Issue
Block a user