|
Re: Possible Bug in Array Shift: msg#00162lang.ruby.rails.core
On 23-Sep-06, at 8:41 PM, Bob Hutchison wrote: > > Hi, > > I've described a problem with the implementation of Array shift in > Ruby 1.8.4 here: > > <http://recursive.ca/hutch/index.php?p=361> > The following illustrates the problem on OS X (and I believe linux) accumulator = [] first = true 10.times do |i| a = [] a << "!" * 10000000 #a[0] = nil a.shift accumulator << a GC.start stdout = `ps v -p #{ Process.pid }` stdout = stdout.split(%r/\n/) printf("\n %s\n", stdout.first) if first printf("%6d:: %s\n", i, stdout.last) first = false end --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@xxxxxxxxxxxxxxxx To unsubscribe from this group, send email to rubyonrails-core-unsubscribe@xxxxxxxxxxxxxxxx For more options, visit this group at http://groups.google.com/group/rubyonrails-core -~----------~----~----~----~------~----~------~--~---
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Possible Bug in Array Shift, Bob Hutchison |
|---|---|
| Next by Date: | Re: Possible Bug in Array Shift, Zed A. Shaw |
| Previous by Thread: | Possible Bug in Array Shift, Bob Hutchison |
| Next by Thread: | Re: Possible Bug in Array Shift, Zed A. Shaw |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |