golang/go

encoding/json: Unmarshal & json.(*Decoder).Token report different values for SyntaxError.Offset for the same input

Open

#34,543 建立於 2019年9月25日

在 GitHub 查看
 (5 留言) (1 反應) (0 負責人)Go (19,008 fork)batch import
NeedsInvestigationhelp wanted

倉庫指標

Star
 (133,883 star)
PR 合併指標
 (30 天內沒有已合併 PR)

描述

What version of Go are you using (go version)?

Does this issue reproduce with the latest release?

Yes.

What operating system and processor architecture are you using (go env)?

What did you do?

https://play.golang.org/p/zkVEGITpYIo

What did you expect to see?

The same Offset for the two error cases, as it is the same input.

What did you see instead?

Different Offset.

貢獻者指南