From: Robert Dober Date: 2007-01-27T20:12:31+09:00 Subject: Re: pass by reference? ------=_Part_55736_28720951.1169896349485 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline On 1/27/07, dblack@wobblini.net wrote: > > Hi -- > > That's a somewhat different point, though, having to do with variable > scope and (re)assignment semantics. What you're doing here > essentially is: > > a = "low" > b = a > b = "hi" > puts a # low > > That's going to happen whether a method call is involved or not. David, it is not my fault that parameter passing by value has the same semantics as reference assignment ;) (it probably is what is happening behind the scenes, a new reference is allocated and the formal parameter is copied to it). Do you see what I wanted to show? Cheers Robert David > > -- > Q. What is THE Ruby book for Rails developers? > A. RUBY FOR RAILS by David A. Black (http://www.manning.com/black) > (See what readers are saying! http://www.rubypal.com/r4rrevs.pdf) > Q. Where can I get Ruby/Rails on-site training, consulting, coaching? > A. Ruby Power and Light, LLC (http://www.rubypal.com) > > -- "The best way to predict the future is to invent it." - Alan Kay ------=_Part_55736_28720951.1169896349485--