At 10:41 PM 6/26/01 +0900, Eric Jacoboni wrote:
> >>>>> "Albert" == Albert Wagner <alwagner / tcac.net> writes:
>
>Albert> Just curious, what did you expect to happen?  What model do
>Albert> you hold in your head concerning names and inheritance that is
>Albert> violated by misnaming an object?
>
>In fact, "my head" has some problem to justify that there is two
>objects of different classes that can be assigned to each other (i'm
>rather experienced with strong typing languages).

That's because you're thinking of C++ and its copy semantics (i.e., when 
you say

anObject = anotherObject;

anObject keeps its identity and its data members are changed so that they 
equal the corresponding data members of anotherObject).
Ruby has references, i.e., bindings of objects to variables. A variable 
"is" not the object it refers to. It is just a label that you stick on an 
object in order to retrieve it later.
In Ruby (or Python, or possibly other weakly-typed languages),

a = "Hello world"
b = 1
b = a

does not mean that you modify 1 so that it becomes equal to "Hello world".
It just means that:

first you stick the label "a" on the string "Hello world";
then you stick the label "b" on the integer 1;
finally, you remove the label "b" from 1 and stick it on the object with 
the label "a" already on it, i.e., "Hello world".

Strings stay strings. Integers stay integers. Labels are moved between 
objects of different types. It might take a while to get used to this view 
of things, but its rationale is sound.

Hope this helps,
                 Luigi