2 ms·
What you describe for JSON is already the case in Go; the stdlib json parser does simply throw out any extra fields on deserialisation.
by CamouflagedKiwi 5y ago
What you describe for JSON is already the case in Go; the stdlib json parser does simply throw out any extra fields on deserialisation.
- morelisp 5y agoIn fact it's difficult-to-impossible to get the opposite (only json.Decoder supports a strict mode, and as soon as one intermediate type implements UnmarshalJSON it stops getting propagated).