Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
GitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
Slice element types are 'masked' when reflect.Value.Index is called on slices of interfaces #39096
What version of Go are you using (
you are doing 2 different things
this is not limited to reflect
Hm - very interesting, thanks for the prompt response !
Would you not agree, though, that when the documented behavior is: "Index returns the i'th element of v",
If not, could you point to a use case that breaks, if Index had returned such equivalence ?
Thanks again for your time - much appreciated.
i expect the result to be the same as :
which is an
example that breaks: you want to set the i'th element to something else, if the type didn't match, with your proposal it wouldn't work