From: "Ara.T.Howard" Date: 2004-04-04T04:24:22+09:00 Subject: Re: Learning Ruby, was a C geek... On Sun, 4 Apr 2004, Kent S. wrote: > Sure. Here's what I've got by reading ruby.core: > > 1. lambda{} is the same thing as Proc.new{}, except lambda has an arity > checker plus it rescues 'call' method for LocalJumpError. > > 2. proc{} is deprecated in favor of lambda{}. > > 3. Proc.new without an associated block is defined like this: > > def method(&block) > end > > equals > > def method > block = Proc.new > end > > and as I know, matz wants to deprecated this Proc.new usage as well. > > Cheers, > Kent. very cool - good to know. -a > > On Apr 3, 2004, at 1:24 PM, Ara.T.Howard wrote: > > > On Sun, 4 Apr 2004, Kent S. wrote: > > > >> lambda is almost the same thing as Proc.new. Consider this: > > > > can you elaborate for those of us who are seeing double after a really > > long > > week? > > > > -- =============================================================================== | EMAIL :: Ara [dot] T [dot] Howard [at] noaa [dot] gov | PHONE :: 303.497.6469 | ADDRESS :: E/GC2 325 Broadway, Boulder, CO 80305-3328 | URL :: http://www.ngdc.noaa.gov/stp/ | TRY :: for l in ruby perl;do $l -e "print \"\x3a\x2d\x29\x0a\"";done ===============================================================================