From: ts Date: 2005-09-28T21:31:45+09:00 Subject: Re: Object private methods >>>>> "P" == Paolino writes: P> Wasn't enough to operate inside a singleton and define a method_added P> hook to paste the added method in Object private space? Too complex what you do :-) and don't forget that main, for ruby, is an object also it need the distinction between self and ruby_class at least for this case moulon% cat b.rb #!/usr/bin/ruby class A end A.class_eval do p self def a puts "A#a" end end A.instance_eval do p self def a puts "A::a" end end A.a A.new.a moulon% moulon% ./b.rb A A A::a A#a moulon% Guy Decoux