Project

General

Profile

Bug #4882

Delegator#methods should accept the singleton flag argument

Added by julik (Julik Tarkhanov) almost 8 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
Normal
Target version:
-
ruby -v:
ruby 1.9.2p180 (2011-02-18 revision 30909) [i386-darwin9.8.0]
Backport:
[ruby-core:37118]

Description

In the new version of delegate.rb

def methods
...
end

does not accept the "also_declared_on_class" argument, which causes failures for libraries that call Object#methods with an argument and therefore excercise this functionality.
On a sidenote, Object#methods somehow is not documented for 1.9 - but maybe I looked in the wrong place?

This is probaby relevant for rubyspec as well so I've filed it under https://github.com/rubyspec/rubyspec/pull/55

If the idea is to remove Object#methods or Object#methods with arity of 1 only it would be good to drop it on Object as well so that explosions are louder and the relevant calling code is fixed asap.


Related issues

Related to Ruby trunk - Bug #3844: Kernel.methods(false) not documentedClosed09/17/2010Actions

Associated revisions

Revision 6e56d645
Added by naruse (Yui NARUSE) over 7 years ago

  • lib/delegate.rb (Delegator#methods): Kernel#methods receives zero or one argument. [ruby-core:37118] [Bug #4882]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33939 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

Revision 33939
Added by naruse (Yui NARUSE) over 7 years ago

  • lib/delegate.rb (Delegator#methods): Kernel#methods receives zero or one argument. [ruby-core:37118] [Bug #4882]

Revision 33939
Added by naruse (Yui NARUSE) over 7 years ago

  • lib/delegate.rb (Delegator#methods): Kernel#methods receives zero or one argument. [ruby-core:37118] [Bug #4882]

Revision 33939
Added by naruse (Yui NARUSE) over 7 years ago

  • lib/delegate.rb (Delegator#methods): Kernel#methods receives zero or one argument. [ruby-core:37118] [Bug #4882]

Revision 33939
Added by naruse (Yui NARUSE) over 7 years ago

  • lib/delegate.rb (Delegator#methods): Kernel#methods receives zero or one argument. [ruby-core:37118] [Bug #4882]

Revision 33939
Added by naruse (Yui NARUSE) over 7 years ago

  • lib/delegate.rb (Delegator#methods): Kernel#methods receives zero or one argument. [ruby-core:37118] [Bug #4882]

Revision 33939
Added by naruse (Yui NARUSE) over 7 years ago

  • lib/delegate.rb (Delegator#methods): Kernel#methods receives zero or one argument. [ruby-core:37118] [Bug #4882]

History

Updated by naruse (Yui NARUSE) almost 8 years ago

  • Status changed from Open to Assigned
  • Assignee set to matz (Yukihiro Matsumoto)
#2

Updated by naruse (Yui NARUSE) over 7 years ago

  • Status changed from Assigned to Closed
  • % Done changed from 0 to 100

This issue was solved with changeset r33939.
Julik, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.


  • lib/delegate.rb (Delegator#methods): Kernel#methods receives zero or one argument. [ruby-core:37118] [Bug #4882]

Also available in: Atom PDF