]> git.feebdaed.xyz Git - 0xmirror/go.git/commit
encoding/json/jsontext: add symbolic Kind constants
authorDamien Neil <dneil@google.com>
Mon, 8 Dec 2025 22:22:12 +0000 (14:22 -0800)
committerGopher Robot <gobot@golang.org>
Thu, 11 Dec 2025 17:37:03 +0000 (09:37 -0800)
commit5818c9d714f1a8abeb76ec5d75ad0e0560e8d780
tree862b68a048789dd998059fdcea397ab53d5bcabf
parent9de6468701f4def1bbdc737e8ad1327f2cfaecc8
encoding/json/jsontext: add symbolic Kind constants

Add constants for each possible Kind value (KindNull, KindTrue, etc.).
Leave the values unchanged ('n', 't', etc.).
Update documentation to reference the symbols.

Fixes #71756

Change-Id: Ib33b2ad9ee55f6f547d9e6a1c5a7f00c8400d3d3
Reviewed-on: https://go-review.googlesource.com/c/go/+/728420
Auto-Submit: Damien Neil <dneil@google.com>
Reviewed-by: Joseph Tsai <joetsai@digital-static.net>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
src/encoding/json/jsontext/decode.go
src/encoding/json/jsontext/encode.go
src/encoding/json/jsontext/token.go
src/encoding/json/jsontext/value.go