[go-nuts] Re: encoding/json: unexpected behaviour when unmarshalling into struct with interface{} field

2017-05-02 Thread Frits van Bommel
On Tuesday, May 2, 2017 at 10:53:36 PM UTC+2, Brian Stengaard wrote: > > > On Tuesday, 2 May 2017 16:02:47 UTC-4, Pierre Curto wrote: >> >> Hello, >> >> My guess: >> If you dont pass in a pointer, then you pass a value. >> What would be the point of updating the value that you will never see and

[go-nuts] Re: encoding/json: unexpected behaviour when unmarshalling into struct with interface{} field

2017-05-02 Thread Brian Stengaard
On Tuesday, 2 May 2017 16:02:47 UTC-4, Pierre Curto wrote: > > Hello, > > My guess: > If you dont pass in a pointer, then you pass a value. > What would be the point of updating the value that you will never see and > that will get discarded? > Hence it returns a map that provides the

[go-nuts] Re: encoding/json: unexpected behaviour when unmarshalling into struct with interface{} field

2017-05-02 Thread pierre . curto
Hello, My guess: If you dont pass in a pointer, then you pass a value. What would be the point of updating the value that you will never see and that will get discarded? Hence it returns a map that provides the unmarshaled values so at least you have something to work with. Le mardi 2 mai 2017