From: SpringFlowers AutumnMoon Date: 2007-09-27T22:45:15+09:00 Subject: Ruby's a = b vs PHP5's $obj1 =& $obj2 Just want to confirm Ruby's a = b is the same as PHP5's $obj1 = $obj2 in other words, the reference is copied. While $obj1 =& $obj2 or $obj1 = &$obj2 in both PHP4 and PHP5 isn't the same as Ruby's a = b $obj1 and $obj2 just become synonyms... and after $obj1 = new Foo("foo1"); $obj2 =& $obj1 $obj2 = new Foo("bar1"); $obj1 and $obj2 have the same content, as they are just synonyms. (not a clone, not same reference, but just synonyms). The "foo1" object is garbage-collected since no one is referencing it. this is giving me an initial headache... until maybe after i get used to it. -- Posted via http://www.ruby-forum.com/.