Actions
Bug #12809
closedpassing a proc to Kernel#lambda does not create a lambda
Bug #12809:
passing a proc to Kernel#lambda does not create a lambda
Actions
Added by sylvain.joyeux (Sylvain Joyeux) almost 10 years ago. Updated almost 10 years ago.
Current behavior is intentional design.
If "lambda" change the lambda-ness of the given block,
the author of "proc { |a| a * 2 }" can not know how the block is interpreted.
This is what the design try to avoid.
Rather, it may be possible to raise error on "lambda" with non-lambda proc object.
This is different issue, though.