From: matz@... (Yukihiro Matsumoto) Date: 2002-07-31T14:12:57+09:00 Subject: [ruby-dev:17853] Re: undef_method ? まつもと ゆきひろです In message "[ruby-dev:17851] undef_method ?" on 02/07/31, Shin-ichiro HARA writes: |test.rb:4:in `undef_method': undefined method `foo' for class `C' (NameError) | from test.rb:4:in `bar' | from test.rb:7 | |が、バグですかね。ruby 1.6.7 (2002-07-11) [i386-cygwin] です。 バグです。とりあえず回避策としては |class C | def foo; 0; end | def C.bar | self.module_eval{undef_method "foo"} | end |end |C.bar としてください。