On Fri, Apr 20, 2012 at 9:22 AM, Gaurav C. <lists / ruby-forum.com> wrote:
> My class is defined as,
>
>    
Please do not do this.  Rather use composition to achieve what you want.

> and I need to override the []= method.

If you do it, you need to override *all* manipulating methods because
otherwise it is not guaranteed that all elements in the Array will be
instances of Word.

Kind regards

robert

-- 
remember.guy do |as, often| as.you_can - without end
http://blog.rubybestpractices.com/