From: Brian Candler Date: 2011-04-21T00:18:51+09:00 Subject: Re: anonymous closures with Proc,new, lambda and -> Michael Edgar wrote in post #993817: > Proc > doesn't implement #initialize, so it bubbles up to Object#initialize. > Since Object#initialize just takes any number of arguments and ignores > them, providing an argument to Proc.new doesn't raise. So I think the question becomes: why does Object#initialize accept any number of arguments in 1.9? It doesn't in 1.8. $ ruby -ve 'Object.new(1,2,3)' ruby 1.8.7 (2010-06-23 patchlevel 299) [x86_64-linux] -e:1:in `initialize': wrong number of arguments (3 for 0) (ArgumentError) from -e:1:in `new' from -e:1 $ ruby192 -ve 'Object.new(1,2,3)' ruby 1.9.2p0 (2010-08-18 revision 29036) [x86_64-linux] $ -- Posted via http://www.ruby-forum.com/.