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
What does 'go version' print?
go version go1.3.3 linux/amd64
What steps reproduce the problem?
http://play.golang.org/p/MQmD9eJmYY
1. Define type with underlying type []byte
2. Marshal a value of said type
3. Try to Unmarshal the result from Marshal
What happened?
Received an error "json: cannot unmarshal string into Go value of type
main.Bytes"
What should have happened instead?
Marshal should either refuse to encode the type, or Unmarshal should unmarshal the
result correctly.
The error happens because the encoding process compares against the slice element type,
while the decoding process compares against the slice type.
The text was updated successfully, but these errors were encountered:
by 2852914@wessie.info:
The text was updated successfully, but these errors were encountered: