-
Notifications
You must be signed in to change notification settings - Fork 18k
encoding/json: ignore mismatched null during unmarshal? #2540
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Labels
Milestone
Comments
I agree but isn't it so that the resulting struct is identical with or without the applied change? The only difference seems to be that there is an error returned. Upon checking the status of the returned error I would note that something went wrong and act accordingly when in fact there was nothing wrong other than that the unmarshalling noted a null string and decided not to set that struct element value. I may have missed something crucial in the code but to me it seems at least wrong to return an error in this case although I agree that null is not a string. Henrik |
Fixed by: https://golang.org/cl/6759043/ |
This issue was closed by revision c90739e. Status changed to Fixed. |
CL https://golang.org/cl/100430043 mentions this issue. |
This issue was closed.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
by dahankzter:
The text was updated successfully, but these errors were encountered: