On Tue, Apr 30, 2019 at 4:31 PM wrote:
> In the method, I can debug and see that the struct got created with map and
> its key value pair, however when the method returns to the caller, the struct
> is there PI and cat initialised, but the key value pairs disappear from the
> map. Is this beha
I have a map inside a struct like following -
type DP struct {
PI string
cat map[string]PS
}
Here, PS is another struct having two string fields.
There is method where I create DP struct, initialise the map and put a
key-value pair to it.
I append this DP struct to an array and return fr