Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(193)

Issue 6460044: code review 6460044: encoding/json: handle anonymous fields (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
1 year, 8 months ago by rsc
Modified:
1 year, 4 months ago
Reviewers:
knieriem
CC:
golang-dev, niemeyer
Visibility:
Public.

Description

encoding/json: handle anonymous fields

Fixes issue 3069.

Patch Set 1 #

Patch Set 2 : diff -r 86c7b6d67466 https://code.google.com/p/go/ #

Patch Set 3 : diff -r bf1b1141ccbf https://code.google.com/p/go/ #

Total comments: 8

Patch Set 4 : diff -r df382f6986cf https://code.google.com/p/go/ #

Patch Set 5 : diff -r 56c7453d488f https://code.google.com/p/go/ #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+395 lines, -141 lines) Patch
M src/pkg/encoding/json/decode.go View 1 2 3 2 chunks +29 lines, -54 lines 0 comments Download
M src/pkg/encoding/json/decode_test.go View 1 2 3 5 chunks +169 lines, -29 lines 0 comments Download
M src/pkg/encoding/json/encode.go View 1 2 3 5 chunks +197 lines, -58 lines 1 comment Download

Messages

Total messages: 8
rsc
Hello golang-dev@googlegroups.com, I'd like you to review this change to https://code.google.com/p/go/
1 year, 8 months ago #1
rsc
+gustavo
1 year, 8 months ago #2
niemeyer
Thanks for handling this Russ. Just a couple of questions: http://codereview.appspot.com/6460044/diff/4001/src/pkg/encoding/json/decode.go File src/pkg/encoding/json/decode.go (right): http://codereview.appspot.com/6460044/diff/4001/src/pkg/encoding/json/decode.go#newcode504 ...
1 year, 7 months ago #3
rsc
PTAL http://codereview.appspot.com/6460044/diff/4001/src/pkg/encoding/json/decode.go File src/pkg/encoding/json/decode.go (right): http://codereview.appspot.com/6460044/diff/4001/src/pkg/encoding/json/decode.go#newcode504 src/pkg/encoding/json/decode.go:504: if strings.EqualFold(ff.name, key) { On 2012/08/31 21:26:45, niemeyer ...
1 year, 7 months ago #4
niemeyer
LGTM, thanks.
1 year, 7 months ago #5
rsc
*** Submitted as http://code.google.com/p/go/source/detail?r=a9fc9baa621b *** encoding/json: handle anonymous fields Fixes issue 3069. R=golang-dev, n13m3y3r CC=golang-dev ...
1 year, 7 months ago #6
knieriem
In case I want to encode a struct containing an anonymous field based on a ...
1 year, 4 months ago #7
rsc
1 year, 4 months ago #8
On Mon, Nov 26, 2012 at 4:17 PM,  <mt4swm@googlemail.com> wrote:
> In case I want to encode a struct containing an anonymous
> field based on a predeclared type, the encoder will panic
> in typeFields():
>         panic: reflect: NumField of non-struct type [recovered]

Thanks. Looks like this is issue 4474.

Russ
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld 1274:9b9295c7fd64