From: Robert Klemme Date: 2003-03-27T21:13:56+09:00 Subject: Re: What are the differences between Ruby's blocks and Python's lambdas? "Mauricio Fern�ndez" schrieb im Newsbeitrag news:20030327090007.GC902@student.ei.uni-stuttgart.de... > ahah, I was thinking the other way around, sorry :-) > Something like "how do I call a proc the same way as a method (downcase)?" > ie., some way to do > pp = proc { |x| x + 1 } > .... MAGIC .... > pp(1) I think you can't other than something like @pp = proc { |x| x + 1 } def pp(*args) @pp.call(*args) end pp(1) The reason is that ruby tries to find a method "pp" in the current instance if you directly issue pp(1). regards robert