Skip to content
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

core/state/snapshot: remove noop map item assignment #24659

Merged
merged 1 commit into from
Apr 7, 2022

Conversation

karalabe
Copy link
Member

@karalabe karalabe commented Apr 7, 2022

This line is not necessary, it reassigned an entry to a map, but that entry originated from the same map. I think this "noop" line originated from a previous code where the entry was a slice. However, if the entry being retrieved and reassigned is a map, that is a pointer internally in Go, so modifying it does not change the outer structure, thus no need for the reassignment.

@karalabe karalabe added this to the 1.10.18 milestone Apr 7, 2022
@karalabe karalabe merged commit 9fd8825 into ethereum:master Apr 7, 2022
sidhujag pushed a commit to syscoin/go-ethereum that referenced this pull request Apr 12, 2022
core/state/snapshot: remove noop map item assignment
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants