New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[pdata] Map.Remove
mutates value returned by Map.Get
#5476
Comments
@bogdandrutu I believe this is a side-affect of this change #2017 . Not sure if it warrants bringing back the following Map representation
I would say we should. WDYT? |
Map.Delete
mutates values returned by Map.Get
Map.Delete
mutates values returned by Map.Get
Map.Delete
mutates value returned by Map.Get
This is true for other slices, and I think we specifically told (was there at one point at least if I remember) in the description that instances returned by |
@dmitryax without that optimization we spend lots and lots of CPU allocating 1000s of small objects :)) |
BTW, this and other optimization won't be necessary and won't cause problems like this if we move to https://github.com/splunk/exp-lazyproto :-) |
Map.Delete
mutates value returned by Map.Get
Map.Remove
mutates value returned by Map.Get
Removing from 1.0 milestone since fixing it is not a breaking change for the pdata API |
Map.Delete
doesn't work as a clean map interface and mutates values returned byMap.Get
. The following snippetprints
instead of expected
The text was updated successfully, but these errors were encountered: