For the record, I've just opened https://github.com/golang/go/issues/48752
to track this.
On Thursday, August 26, 2021 at 3:29:09 PM UTC+12 ben...@gmail.com wrote:
> Every site you access probably uses Google analytics or something similar.
>>
>> It is often used to understand usage patterns,
1. Check the error result code from json.Unmarshal. It will tell you when
something is wrong.
2. However in your case, it's much simpler. The JSON contains an element
{"content": ... } but your type Rs doesn't have a "Content" member.
Therefore, it doesn't match any element in the incoming
Hi all, I am using json.Unamarshal() api to get back the response values
sent as a response by the remote API.
But I am unable to get the response values.
When printed the output it displayed as
{0 }
But the same response when converted to string, I could see all the values
in it.
Few golang
I observed that the regexp package has a pool of onePassMachine objects,
which I believe exist to avoid allocation due to heap escape caused by
calling through the 'inputs' interface.
I expected that, using generics, I can replace that interface with a type
parameter, and hence do away with
I don't think so. There is no way to decompose structs as part of
constraints, so you can't generalize over them easily. There is also no way
to generalize over an arbitrary number of types, which would be necessary
to write a signature of `ReturnFunc`.
On Sun, Oct 3, 2021 at 5:41 PM mi...@ubo.ro
I have developed a library that depends very much on reflect package. It
caches a specific type and return a function that encodes(does something
with) with that kind /type of data. Think of defining database schema using
types and generating functions to validate/update/insert data.
I reduced