From: Alexandre Mutel Date: 2009-11-19T00:42:50+09:00 Subject: How to overide "include" method? I tried several way, but didn't found any to override the behavior of the "include" method. I would like to override it's behavior to accept a string as an argument and perform a special include based on that.. so I tried something like this: class Module def include(module1, *smth) # :doc: puts "In my include #{self}" if ( module1.is_a? String) instance_eval(File.read(module1), module1) else super module1,*smth end end end without any success, this method is nether called. Any ideas? -- Posted via http://www.ruby-forum.com/.