U
_ugly
I've been doing some unit tests with ruby -W. Wow did I have a lot to
clean up but I still can't get past one warning. I've boiled it down
to this example:
o = Object.new
def o.foo
'foo'
end
class << o
undef_method :foo
end
def o.foo
'foo'
end
# undef_method_test.rb:8: warning: redefine foo
Is my head broken or ruby -W broken? I'm thinking the former.
TIA,
_ugly
clean up but I still can't get past one warning. I've boiled it down
to this example:
o = Object.new
def o.foo
'foo'
end
class << o
undef_method :foo
end
def o.foo
'foo'
end
# undef_method_test.rb:8: warning: redefine foo
Is my head broken or ruby -W broken? I'm thinking the former.
TIA,
_ugly