From: "ko1 (Koichi Sasada)" Date: 2013-02-14T10:38:47+09:00 Subject: [ruby-core:52244] [ruby-trunk - Bug #7806][Open] inconsistency between Method#inspect and Method#name Issue #7806 has been updated by ko1 (Koichi Sasada). Status changed from Closed to Open Assignee set to nobu (Nobuyoshi Nakada) Target version set to next minor Nobu, you add new method Method#original_name on r39223. Could you explain about it, why and what? I make the target version of this ticket `next minor'. If it should be applied to 2.0.0, please change it and make backport ticket. ---------------------------------------- Bug #7806: inconsistency between Method#inspect and Method#name https://bugs.ruby-lang.org/issues/7806#change-36268 Author: Hanmac (Hans Mackowiak) Status: Open Priority: Normal Assignee: nobu (Nobuyoshi Nakada) Category: Target version: next minor ruby -v: ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-linux] =begin it seems that Method#inspect does some magic with alias methods code: class A def xyz end alias ver xyz end p A.instance_method(:ver) # p A.instance_method(:ver).name #:ver a=A.new p a.method(:ver) # p a.method(:ver).name #:ver shouldn't the #(({inspect})) method use the #(({name})) one? maybe #(({alias?})) and #(({alias_target})) and maybe (({inspect})) return something like ((%#%)) so it can be seen that the method is an alias? PS: sorry i cant get the code tag working currectly -- http://bugs.ruby-lang.org/