flatbuffers
flatbuffers copied to clipboard
[C++] get default value for field
Is it possible to get the default value for a field?
I find myself wanting to get the default value without having to build and/or parse an object. Ideally, in C++ that value should be available as a constexpr
. As far as I can see, currently the default value is hardcoded in several places in the *_generated.h
header but there is no way of getting it without creating an object.
Not currently, but I would be supportive of such a constexpr accessor.
This issue is stale because it has been open 6 months with no activity. Please comment or label not-stale
, or this will be closed in 14 days.
Hi, may I take this up? Looks like something I can contribute to.