easyjson
easyjson copied to clipboard
Inline struct fields are omitted in case of name collision
Consider following code:
type Outer struct {
Inner
A int64 `json:"a"`
B interface{} `json:"b"`
}
type Inner struct {
A map[string]float64 `json:"innerA"`
B string `json:"innerB"`
}
Serializing Outer{} using encoding/json gives us {"innerA":null,"innerB":"","a":0,"b":null}
(snippet), but if we try to do the same in easyjson fields of inner struct are supressed by fields of the outer struct.
I have the same problem
Was this issue fixed from a PR? I see that this issue was closed but has no reference to a fix.
edit: I misread the mention above my comment. It seems this is still an outstanding issue, my bad.