So far, these fields were represented as interface{}, which means that the JSON library parsed these fields. However, they contain opaque data, which makes it very inconvenient to work with such a message. Now, fields with a submessage are represented as json.RawMessage, so that applications can re-parse these submessages into the correct structure more easily.
If the list of types only contains fundamental types, we stick with interface{}.
So far, these fields were represented as
interface{}
, which means that the JSON library parsed these fields. However, they contain opaque data, which makes it very inconvenient to work with such a message. Now, fields with a submessage are represented as json.RawMessage, so that applications can re-parse these submessages into the correct structure more easily.If the list of types only contains fundamental types, we stick with
interface{}
.