Subject: Re: global array of hashes
From: Mario Ruiz <mario betware.com>
Date: Thu, 10 Apr 2008 20:57:06 +0900
References: 297704297705
In-reply-to: 297705
But not in this case:
$globvar=Array.new()
myHash=Hash.new()
myHash["oneValue"]="mygenericvalue"
$globvar[0]=myHash
localvar=$globvar.dup
localvar[0]["oneValue"]="mylocalvalue"
puts $globvar
--
Posted via http://www.ruby-forum.com/.