Unmarshalling is case insensitive as described in the docs:
To unmarshal JSON into a struct, Unmarshal matches incoming object keys to the keys used by Marshal (either the struct field name or its tag), preferring an exact match but also accepting a case-insensitive match. https://pkg.go.dev/encoding/json#Unmarshal
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes
What did you do?
What did you expect to see?
prints 1
What did you see instead?
prints 2
The text was updated successfully, but these errors were encountered: