Bug #1722: Curried Lambda Returns False for #lambda? Despite Having No
"Tricks"
http://redmine.ruby-lang.org/issues/show/1722
Author: Run Paint Run Run
Status: Open, Priority: Low
Category: core
ruby -v: ruby 1.9.2dev (2009-07-03 trunk 23948) [i686-linux]
A curried lambda returns false for #lambda? despite having identical
"rigid" argument handling.
>> l = lambda {|x|}
=> #<Proc:0x9914b60@(irb):33 (lambda)>
>> l.call(1,2)
ArgumentError: wrong number of arguments (2 for 1)
from (irb):34:in `call'
from (irb):34
from /usr/local/bin/irb:12:in `<main>'
>> l.lambda?
=> true
>> l.curry.lambda?
=> false
>> l.curry[1,2]
ArgumentError: wrong number of arguments (2 for 1)
from (irb):37:in `[]'
from (irb):37
from /usr/local/bin/irb:12:in `<main>'
on 2009-07-03 17:23
on 2009-07-06 02:37
Issue #1722 has been updated by Nobuyoshi Nakada. Status changed from Open to Closed % Done changed from 0 to 100 Applied in changeset r23970. ---------------------------------------- http://redmine.ruby-lang.org/issues/show/1722
Please log in before posting. Registration is free and takes only a minute.
Existing account
(Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
Log in with Google account | Log in with Yahoo account
No account? Register here.