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
While the convention is that a non-nil error implies a nil return value, this is not required. Callers that care about errors should be checking the error before using the value.
I don't see how we can change this without breaking existing usages that are depending on this semantic.
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes it does
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
I have read an invalid csv with csv.Reader
See: https://go.dev/play/p/p66Sy_Z4494
What did you expect to see?
I have expected to receive a nil record and a non-nil error indicating the problem with this line of csv.
What did you see instead?
The method returns a partially parsed record and the appropriate error
ErrQuote
.The method's documentation states this should never happen:
go/src/encoding/csv/reader.go
Lines 188 to 191 in fc106b0
From what I can tell the behavior has changed 6 years ago with this change: 2181653
The text was updated successfully, but these errors were encountered: