Hi, when including Enumerable module in a class, its instances get
the “replace” method in which I’m not interested. Why this method is
added?
It doesn’t appear in Enumerable.
Thanks.
Hi, when including Enumerable module in a class, its instances get
the “replace” method in which I’m not interested. Why this method is
added?
It doesn’t appear in Enumerable.
Thanks.
On Feb 23, 12:30 pm, Iñaki Baz C. [email protected] wrote:
Hi, when including Enumerable module in a class, its instances get
the “replace” method in which I’m not interested. Why this method is added?
It isn’t.
Ruby 1.8.6 p114
class Foo
include Enumerable
end
Foo.instance_methods.include?(‘replace’) => false
Regards,
Dan
El Lunes, 23 de Febrero de 2009, Daniel B.
escribió:> include Enumerable
end
Foo.instance_methods.include?(‘replace’) => false
Sorry, my fault. Thanks a lot.
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.
Sponsor our Newsletter | Privacy Policy | Terms of Service | Remote Ruby Jobs