From: Robert Klemme Date: 2010-08-27T17:14:47+09:00 Subject: Re: Initialise 2010/8/26 Brian Candler : > class Object >  alias :old_initialize :initialize >  def initialize(*args,&blk) >    if respond_to? :initialise >      initialise(*args,&blk) >    else >      old_initialize(*args,&blk) >    end >  end > end > > class Foo >  def initialize(n) >    @n = n >  end > end > > class Bar >  def initialise(m) >    @m = m >  end > end > > p Foo.new(123) > p Bar.new(456) > > You get a warning about redefining initialize, but it seems to work. What about inheritance especially in light of "super"? I'm with Joseph here: better adjust to the programming language and stick with "initialize". >> I suppose my only recourse now is to start >> hacking on the Ruby source and get my patch submitted in time for Ruby >> 2.0 :) > > That will be released some time between perl 6 and hell freezing over > :-) Can't be too long though. :-) Cheers robert -- remember.guy do |as, often| as.you_can - without end http://blog.rubybestpractices.com/