FAQ
In the example http://golang.org/pkg/sync/atomic/#example_Value_readMostly
why are we creating a new copy of map1 in map2 before storing it into Value
again? If the consumers are bound to use only the read and update methods
(by some mechanism), shouldn't we be able to update the same map and store
it back? What are the pitfalls that are being avoided by making a full
copy?


--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

Discussion Posts

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 1 of 3 | next ›
Discussion Overview
groupgolang-nuts @
categoriesgo
postedDec 23, '14 at 11:42a
activeDec 23, '14 at 12:32p
posts3
users3
websitegolang.org

People

Translate

site design / logo © 2021 Grokbase