From: Morton Goldberg Date: 2006-08-24T01:37:49+09:00 Subject: Re: Call functions of superclass To satisfy your curiosity, #! /usr/bin/ruby -w class Parent def something puts "Parent something" end def another puts "Parent another" end end class Child < Parent def something puts "Child something" super.another end def another puts "Child another" end end Child.new.something Child something Parent something /Users/mg/Desktop/test.rb:19:in `something': undefined method `another' for nil:NilClass (NoMethodError) from /Users/mg/Desktop/test.rb:28 From which I conclude that 'super.another' is parsed as 'super nil.another' Regards, Morton On Aug 23, 2006, at 11:44 AM, Julian 'Julik' Tarkhanov wrote: > class Parent > def something > end > > def another > # do foo > end > end > > class Child < Parent > def something > super.another # call _another_ instance method BUT of the > superclass, not one's own > end > > def another > # do bar instead of foo > end > end