Method#source_location and Methods Created with `attr`
$ cat /tmp/attr.rb
$ ruby -v /tmp/attr.rb
ruby 1.9.2dev (2009-09-11) [i686-linux]
Is it feasible to have Method#source_location work with methods created with attr(and friends)? Given that a common use for this feature is to extract documentation, it would be helpful if such methods could be located by introspection.
Updated by mame (Yusuke Endoh) over 10 years ago
- Assignee changed from yugui (Yuki Sonoda) to wanabe (_ wanabe)
Matz or Yugui, could you approve this?
Yugui has agreed with this feature on IRC.
But she said she had no responsibility for Method#source_location.
(I had misunderstood that she had committed it)
Well, because this feature is trivial, I guess anyone won't disagree.
Wanabe, could you apply your patch?
If you are reluctant to commit it without explicit approval, I'll
commit it on my own responsibility.
Yusuke Endoh email@example.com