Skip to content

Commit

Permalink
Fix: new cow needed
Browse files Browse the repository at this point in the history
  • Loading branch information
tidwall committed Apr 20, 2022
1 parent 14cbb4c commit 63baa09
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions map.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ func (tr *Map[K, V]) Copy() *Map[K, V] {
tr2 := new(Map[K, V])
*tr2 = *tr
tr2.cow = new(cow)
tr.cow = new(cow)
return tr2
}

Expand Down

0 comments on commit 63baa09

Please sign in to comment.