What happens when appending to a slice exceeds the backing capacity?

https://play.golang.org/p/mVezWL4Cbe

In the example given, appending within capacity on line 20 modifies the 
backing array at the successive index.
But on line 26, when appending exceeds the capacity, the backing array is 
no longer modified. So where are those additional elements stored?

Also the capacity for this new backing store is 12, this is to amortize 
performance correct?

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to