mirror of
https://github.com/google/flatbuffers.git
synced 2026-11-08 05:09:09 +00:00
Reviewed-on: BigfootDev/flatbuffers-bigfoot#1 Co-authored-by: Romain BOULLARD <romain.boullard@protonmail.com>
18 lines
548 B
Plaintext
18 lines
548 B
Plaintext
namespace RequiredTableDefaultTestNS;
|
|
|
|
table Inner {
|
|
value: uint32;
|
|
}
|
|
|
|
// `required_inner` has no default in the wire format (tables can't have one),
|
|
// but Pack()/Verify() both reject a buffer where it is missing - so the
|
|
// native default constructor must never leave it null. `optional_inner` is
|
|
// the same field type without `required`, kept alongside it to confirm the
|
|
// fix only changes required table fields, not every table pointer field.
|
|
table Holder {
|
|
required_inner: Inner (required);
|
|
optional_inner: Inner;
|
|
}
|
|
|
|
root_type Holder;
|