From: Richard Lionheart Date: 2004-04-28T18:19:12+09:00 Subject: Re: Problem assigning an Array object to an Array-subclass object Hi Dick, Gotcha! Applying your ideas, modified slightly I believe, I tested: # F:\_Projects_Current\_Projects_Ruby\P001f-Arrays#3\MyArr3.rb a = [] b = [] a = %w( foo bar ack) b = %w(eeny meeny miney mo) puts "Before override: a = #{a.to_s}, b = #{b.to_s}" class Array def to_s join("; ") end end a = %w( foo bar ack) b = %w(eeny meeny miney mo) puts "After override: a = #{a.to_s}, b = #{b.to_s}" ####### Got results: >ruby MyArr3.rb Arg1 Arg2 Before override: a = foobarack, b = eenymeenymineymo After override: a = foo; bar; ack, b = eeny; meeny; miney; mo >Exit code: 0 ##### Neat stuff! Thanks, Richard --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.665 / Virus Database: 428 - Release Date: 4/26/2004