go-capnp
go-capnp copied to clipboard
Text format includes null fields
The text format marshaller includes all fields in the output, even those with pointer type where the pointer is null. This differs from the C++ version, which only marshals pointer-typed fields if they are non-null. Some apps do actually depend on nullness, so IMO it's useful to represent this precisely in the text format.
I haven't tested, but I think this might also imply that a recursive struct type will lead to infinite recursion?
Sounds like a good change. I'm happy to review a PR for this.