>From what I recall we did have one user who did have this problem and
it was something like mail processing where all header lines got
sliced from an array of the entire email and then retained... :)
In this case, the COW leak was nearly impossible to understand until
visually inspecting the lin
Typical case I've used it was to slice things for columnar display. I end up
using the entire array, but just in N chunks of M items at a time.
I don't recall ever taking a slice and discarding the rest.
fwiw.
-Bob
On Oct 26, 2011, at 9:28 AM, Thomas E Enebo wrote:
> Does anyone do
Does anyone do a lot of sliciing (e.g. things like [1...100]) in their
apps. Are they big arrays? Does anyone know a library which does?
-Tom
On Tue, Oct 25, 2011 at 6:46 PM, Charles Oliver Nutter
wrote:
> Long ago when the world was new, Marcin Mielzynski modified our Array
> implementation t
Long ago when the world was new, Marcin Mielzynski modified our Array
implementation to be copy-on-write like MRI. And there was much
rejoicing.
COW helps methods like slice and dup that would normally need to make
a copy of all or part of the source array by wrapping the original
array in "shared