You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{Name:foo Info:[123 34 97 34 58 49 125] JI:[]}
"{\"a\":1}" <---- no whitespace at json.RawMessage
"" <---- json.Unmarshal does not know how to unmarshal the jsoniter.RawMessage which is ok
{Name:foo Info:[32 123 34 97 34 58 49 125] JI:[32 32 32 123 34 98 34 58 49 125]}
" {\"a\":1}" <----- extra whitespace (32 ASCII)
" {\"b\":1}" <----- note the artificial added whitespaces here at the jsoniter.RawMessage for demonstration purposes
The text was updated successfully, but these errors were encountered:
The unmarshalling of a
json.RawMessage
orjsoniter.RawMessage
does not ignore whitespace in front of a the json object:https://play.golang.org/p/Wcao2ty9jJw
Output:
The text was updated successfully, but these errors were encountered: