From: James Coglan Date: 2008-09-30T18:31:17+09:00 Subject: Re: extend keyword in class definition ------=_Part_76520_4775322.1222767133062 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline > > I am a bit surprised by the 'extend Forwardable' line. Can anybody > explain me what this is? Is it the same as 'include Forwardable' or is > it the same as 'class WriterDecorator < Forwardable'? It's neither. extend() is method that all objects have (classes are objects too). It takes the methods from a module (in this case Forwardable) and adds them as singleton methods to the object. Forwardable contains the method 'def_delegators', which we see here has been added as a singleton method to WriterDecorator. ------=_Part_76520_4775322.1222767133062--